]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
iaxs[callno] may go away if we try to avoid the deadlock
authorJoshua Colp <jcolp@digium.com>
Mon, 9 Oct 2006 15:46:53 +0000 (15:46 +0000)
committerJoshua Colp <jcolp@digium.com>
Mon, 9 Oct 2006 15:46:53 +0000 (15:46 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@44760 65c4cc65-6c06-0410-ace0-fbb531ad65f3

channels/chan_iax2.c

index 1b6b62db2b62f0347d95daf7163e6021446291aa..25170551b1d91d6c48ccb45b81e056e31956dc20 100644 (file)
@@ -1710,11 +1710,12 @@ static int iax2_predestroy(int callno)
 
 static void iax2_destroy(int callno)
 {
-       struct chan_iax2_pvt *pvt = iaxs[callno];
+       struct chan_iax2_pvt *pvt;
        struct iax_frame *cur;
        struct ast_channel *owner;
 
 retry:
+       pvt = iaxs[callno];
        gettimeofday(&lastused[callno], NULL);
        
        owner = pvt ? pvt->owner : NULL;