diff options
author | file <file@f38db490-d61c-443f-a65b-d21fe96a405b> | 2006-11-15 22:31:17 +0000 |
---|---|---|
committer | file <file@f38db490-d61c-443f-a65b-d21fe96a405b> | 2006-11-15 22:31:17 +0000 |
commit | f298b7dc446587c2706528a795caecbe0ca9a144 (patch) | |
tree | fbb596dcd05f2a4083fa06aae63011aa0b9a188d /channels/chan_local.c | |
parent | 1f469e3e6f00d8ec1bcfd60f199a40ac8a1e6aa4 (diff) |
Merged revisions 47711 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.2
........
r47711 | file | 2006-11-15 17:29:30 -0500 (Wed, 15 Nov 2006) | 2 lines
Make sure that the pvt structure exists before trying to do fixup on Local channels. (issue #7937 reported by mada123, fix by alamantia with mods by me)
........
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@47712 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'channels/chan_local.c')
-rw-r--r-- | channels/chan_local.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/channels/chan_local.c b/channels/chan_local.c index fe821363d..e1028aa1e 100644 --- a/channels/chan_local.c +++ b/channels/chan_local.c @@ -295,6 +295,10 @@ static int local_write(struct ast_channel *ast, struct ast_frame *f) static int local_fixup(struct ast_channel *oldchan, struct ast_channel *newchan) { struct local_pvt *p = newchan->tech_pvt; + + if (!p) + return -1; + ast_mutex_lock(&p->lock); if ((p->owner != oldchan) && (p->chan != oldchan)) { |