Merged revisions 73319 via svnmerge from
authorJoshua Colp <jcolp@digium.com>
Thu, 5 Jul 2007 13:28:41 +0000 (13:28 +0000)
committerJoshua Colp <jcolp@digium.com>
Thu, 5 Jul 2007 13:28:41 +0000 (13:28 +0000)
https://origsvn.digium.com/svn/asterisk/branches/1.4

................
r73319 | file | 2007-07-05 10:27:40 -0300 (Thu, 05 Jul 2007) | 10 lines

Merged revisions 73318 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r73318 | file | 2007-07-05 10:26:02 -0300 (Thu, 05 Jul 2007) | 2 lines

Actually check to make sure a PBX was started on one of the Local channels instead of blindly assuming it was. (issue #10112 reported by makoto)

........

................

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@73320 65c4cc65-6c06-0410-ace0-fbb531ad65f3

channels/chan_local.c

index 47b862b..beac406 100644 (file)
@@ -474,10 +474,10 @@ static int local_call(struct ast_channel *ast, char *dest, int timeout)
                }
        }
 
-       ast_set_flag(p, LOCAL_LAUNCHED_PBX);
-
        /* Start switch on sub channel */
-       res = ast_pbx_start(p->chan);
+       if (!(res = ast_pbx_start(p->chan)))
+               ast_set_flag(p, LOCAL_LAUNCHED_PBX);
+
        ast_mutex_unlock(&p->lock);
        return res;
 }