diff options
author | mmichelson <mmichelson@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-03-17 14:21:48 +0000 |
---|---|---|
committer | mmichelson <mmichelson@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-03-17 14:21:48 +0000 |
commit | 44ca9a1e379f96d58d411386a77c4aaf082ee999 (patch) | |
tree | 1a940bcb039b9bc3a995ec195d06700eeb74fac9 /apps | |
parent | be57585cb6f5d996364b76761c0022d034face2d (diff) |
Merged revisions 109024 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk
................
r109024 | mmichelson | 2008-03-17 09:21:14 -0500 (Mon, 17 Mar 2008) | 14 lines
Merged revisions 109012 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r109012 | mmichelson | 2008-03-17 09:18:26 -0500 (Mon, 17 Mar 2008) | 6 lines
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
........
................
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.0@109027 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'apps')
-rw-r--r-- | apps/app_chanspy.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/apps/app_chanspy.c b/apps/app_chanspy.c index 32d5e7c0b..ab056e0aa 100644 --- a/apps/app_chanspy.c +++ b/apps/app_chanspy.c @@ -275,8 +275,10 @@ static int channel_spy(struct ast_channel *chan, struct chanspy_ds *spyee_chansp /* 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); ast_verb(2, "Spying on channel %s\n", name); |