[asterisk-commits] mmichelson: trunk r141367 - in /trunk: ./ channels/chan_agent.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Fri Sep 5 16:12:09 CDT 2008


Author: mmichelson
Date: Fri Sep  5 16:12:09 2008
New Revision: 141367

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

........
r141366 | mmichelson | 2008-09-05 16:10:32 -0500 (Fri, 05 Sep 2008) | 7 lines

Agent's should not try to call a channel's indicate callback
if the channel has been hung up. It will likely crash
otherwise

ABE-1159


........

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

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

Modified: trunk/channels/chan_agent.c
URL: http://svn.digium.com/view/asterisk/trunk/channels/chan_agent.c?view=diff&rev=141367&r1=141366&r2=141367
==============================================================================
--- trunk/channels/chan_agent.c (original)
+++ trunk/channels/chan_agent.c Fri Sep  5 16:12:09 2008
@@ -655,7 +655,7 @@
 	struct agent_pvt *p = ast->tech_pvt;
 	int res = -1;
 	ast_mutex_lock(&p->lock);
-	if (p->chan)
+	if (p->chan && !ast_check_hangup(p->chan))
 		res = p->chan->tech->indicate ? p->chan->tech->indicate(p->chan, condition, data, datalen) : -1;
 	else
 		res = 0;




More information about the asterisk-commits mailing list