[asterisk-commits] russell: trunk r80500 - in /trunk: ./ channels/chan_iax2.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Thu Aug 23 12:04:05 CDT 2007


Author: russell
Date: Thu Aug 23 12:04:04 2007
New Revision: 80500

URL: http://svn.digium.com/view/asterisk?view=rev&rev=80500
Log:
Merged revisions 80499 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r80499 | russell | 2007-08-23 12:02:50 -0500 (Thu, 23 Aug 2007) | 3 lines

Fix some code where it was possible for a reference to a peer to not get
released when it should.  Thank you to Marta Carbone for pointing this out!

........

Modified:
    trunk/   (props changed)
    trunk/channels/chan_iax2.c

Propchange: trunk/
------------------------------------------------------------------------------
Binary property 'branch-1.4-merged' - no diff available.

Modified: trunk/channels/chan_iax2.c
URL: http://svn.digium.com/view/asterisk/trunk/channels/chan_iax2.c?view=diff&rev=80500&r1=80499&r2=80500
==============================================================================
--- trunk/channels/chan_iax2.c (original)
+++ trunk/channels/chan_iax2.c Thu Aug 23 12:04:04 2007
@@ -5706,10 +5706,12 @@
 			    /* No specified host, or this is our host */
 				) {
 				res = authenticate(p->challenge, peer->secret, peer->outkey, authmethods, &ied, sin, &p->ecx, &p->dcx);
-				peer_unref(peer);
-				if (!res)
-					break;	
+				if (!res) {
+					peer_unref(peer);
+					break;
+				}
 			}
+			peer_unref(peer);
 		}
 		if (!peer) {
 			/* We checked our list and didn't find one.  It's unlikely, but possible, 




More information about the asterisk-commits mailing list