[asterisk-commits] dvossel: trunk r207225 - /trunk/channels/chan_iax2.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Fri Jul 17 17:07:40 CDT 2009


Author: dvossel
Date: Fri Jul 17 17:07:36 2009
New Revision: 207225

URL: http://svn.asterisk.org/svn-view/asterisk?view=rev&rev=207225
Log:
fixes an error in r203638 CEL commit

(closes issue #15525)
Reported by: elguero
Patches:
      iax2-double-unlock.patch uploaded by elguero (license 37)
      15525.diff uploaded by dvossel (license 671)
Tested by: dvossel


Modified:
    trunk/channels/chan_iax2.c

Modified: trunk/channels/chan_iax2.c
URL: http://svn.asterisk.org/svn-view/asterisk/trunk/channels/chan_iax2.c?view=diff&rev=207225&r1=207224&r2=207225
==============================================================================
--- trunk/channels/chan_iax2.c (original)
+++ trunk/channels/chan_iax2.c Fri Jul 17 17:07:36 2009
@@ -8523,8 +8523,7 @@
 	do {
 		if (ast_channel_trylock(iaxs[callno]->owner)) {
 			DEADLOCK_AVOIDANCE(&iaxsl[callno]);
-		}
-		else {
+		} else {
 			locked = 1;
 			owner = iaxs[callno]->owner;
 		}
@@ -8537,12 +8536,10 @@
 		}
 		ast_set_hangupsource(iaxs[callno]->owner, iaxs[callno]->owner->name, 0);
 		ast_channel_unlock(owner);
-	}
-	if (locked) {
+	} else if(locked) {
 		ast_channel_unlock(owner);
 	}
 }
-
 
 static int socket_process(struct iax2_thread *thread)
 {




More information about the asterisk-commits mailing list