aboutsummaryrefslogtreecommitdiffstats
path: root/channels
diff options
context:
space:
mode:
authormmichelson <mmichelson@f38db490-d61c-443f-a65b-d21fe96a405b>2008-09-05 21:13:06 +0000
committermmichelson <mmichelson@f38db490-d61c-443f-a65b-d21fe96a405b>2008-09-05 21:13:06 +0000
commit9e7d5bcd1e2811b8eda61652920383f5c63e679e (patch)
treec1bc58cd26ee542bf851ab7f232aa3e294926d02 /channels
parent2ac0aaf2d874f704f00d9b8f26505484eb7d31d7 (diff)
Merged revisions 141367 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk ................ r141367 | mmichelson | 2008-09-05 16:12:09 -0500 (Fri, 05 Sep 2008) | 15 lines 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 ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.0@141368 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'channels')
-rw-r--r--channels/chan_agent.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/channels/chan_agent.c b/channels/chan_agent.c
index 5c739234d..f582b7287 100644
--- a/channels/chan_agent.c
+++ b/channels/chan_agent.c
@@ -646,7 +646,7 @@ static int agent_indicate(struct ast_channel *ast, int condition, const void *da
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;