[svn-commits] mmichelson: branch 1.4 r109012 - /branches/1.4/apps/app_chanspy.c

SVN commits to the Digium repositories svn-commits at lists.digium.com
Mon Mar 17 09:18:27 CDT 2008


Author: mmichelson
Date: Mon Mar 17 09:18:26 2008
New Revision: 109012

URL: http://svn.digium.com/view/asterisk?view=rev&rev=109012
Log:
Make sure that we release the lock on the spyee channel if the spyee or spy has hung up

(closes issue #12232)
Reported by: atis


Modified:
    branches/1.4/apps/app_chanspy.c

Modified: branches/1.4/apps/app_chanspy.c
URL: http://svn.digium.com/view/asterisk/branches/1.4/apps/app_chanspy.c?view=diff&rev=109012&r1=109011&r2=109012
==============================================================================
--- branches/1.4/apps/app_chanspy.c (original)
+++ branches/1.4/apps/app_chanspy.c Mon Mar 17 09:18:26 2008
@@ -250,8 +250,10 @@
 
 	/* We now hold the channel lock on spyee */
 
-	if (ast_check_hangup(chan) || ast_check_hangup(spyee))
+	if (ast_check_hangup(chan) || ast_check_hangup(spyee)) {
+		ast_channel_unlock(spyee);
 		return 0;
+	}
 
 	name = ast_strdupa(spyee->name);
 	if (option_verbose >= 2)




More information about the svn-commits mailing list