diff options
author | twilson <twilson@f38db490-d61c-443f-a65b-d21fe96a405b> | 2009-11-09 22:52:43 +0000 |
---|---|---|
committer | twilson <twilson@f38db490-d61c-443f-a65b-d21fe96a405b> | 2009-11-09 22:52:43 +0000 |
commit | 13f66a98a7006e3679079d6a6789eb5088b959e2 (patch) | |
tree | 5e308990a47ff551f9f1a38efc7b01da7e5ad05e /channels/chan_local.c | |
parent | 6d1437aed015ab05587c1392c39d5cf03d0d9574 (diff) |
Merged revisions 229015 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk
........
r229015 | twilson | 2009-11-09 16:50:22 -0600 (Mon, 09 Nov 2009) | 8 lines
Don't crash when bridge->tech_pvt == NULL
This is a similar solution to what is in place for chan_agent
(closes issue #16003)
Reported by: atis
Tested by: twilson
........
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.1@229016 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'channels/chan_local.c')
-rw-r--r-- | channels/chan_local.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/channels/chan_local.c b/channels/chan_local.c index 141f89f5b..b47b9a84a 100644 --- a/channels/chan_local.c +++ b/channels/chan_local.c @@ -177,6 +177,12 @@ static struct ast_channel *local_bridgedchannel(struct ast_channel *chan, struct struct local_pvt *p = bridge->tech_pvt; struct ast_channel *bridged = bridge; + if (!p) { + ast_debug(1, "Asked for bridged channel on '%s'/'%s', returning <none>\n", + chan->name, bridge->name); + return NULL; + } + ast_mutex_lock(&p->lock); if (ast_test_flag(p, LOCAL_BRIDGE)) { |