]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
Fix a deadlock in sig_analog
authorMatthew Nicholson <mnicholson@digium.com>
Tue, 7 Jul 2009 18:24:13 +0000 (18:24 +0000)
committerMatthew Nicholson <mnicholson@digium.com>
Tue, 7 Jul 2009 18:24:13 +0000 (18:24 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@205047 65c4cc65-6c06-0410-ace0-fbb531ad65f3

channels/sig_analog.c

index 556a2443c3c371598a1057496e0fb885a5ea6e49..e397e5f4f9bb24c47e483a6d9fea945f3c249f08 100644 (file)
@@ -536,7 +536,7 @@ static int analog_attempt_transfer(struct analog_pvt *p)
                }
                /* Three-way is now the REAL */
                analog_swap_subs(p, ANALOG_SUB_THREEWAY, ANALOG_SUB_REAL);
-               ast_channel_unlock(p->subs[ANALOG_SUB_THREEWAY].owner);
+               ast_channel_unlock(p->subs[ANALOG_SUB_REAL].owner); /* unlock REAL because THREEWAY has become REAL */
                analog_unalloc_sub(p, ANALOG_SUB_THREEWAY);
                /* Tell the caller not to hangup */
                return 1;