[asterisk-commits] mmichelson: branch 1.4 r185531 - /branches/1.4/channels/chan_sip.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Tue Mar 31 15:56:04 CDT 2009


Author: mmichelson
Date: Tue Mar 31 15:55:47 2009
New Revision: 185531

URL: http://svn.digium.com/svn-view/asterisk?view=rev&rev=185531
Log:
Use AST_SCHED_DEL_SPINLOCK instead of manually using the logic.


Modified:
    branches/1.4/channels/chan_sip.c

Modified: branches/1.4/channels/chan_sip.c
URL: http://svn.digium.com/svn-view/asterisk/branches/1.4/channels/chan_sip.c?view=diff&rev=185531&r1=185530&r2=185531
==============================================================================
--- branches/1.4/channels/chan_sip.c (original)
+++ branches/1.4/channels/chan_sip.c Tue Mar 31 15:55:47 2009
@@ -2215,9 +2215,7 @@
 			 * the packet's retransid will be set to -1. The atomicity of the setting and checking
 			 * of the retransid to -1 is ensured since in both cases p's lock is held.
 			 */
-			while (cur->retransid > -1 && ast_sched_del(sched, cur->retransid)) {
-				DEADLOCK_AVOIDANCE(&p->lock);
-			}
+			AST_SCHED_DEL_SPINLOCK(sched, cur->retransid, &p->lock);
 			free(cur);
 			break;
 		}




More information about the asterisk-commits mailing list