]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
Make ParkedCall application stop execution of the dialplan after hang up
authorJeff Peeler <jpeeler@digium.com>
Wed, 6 May 2009 22:15:19 +0000 (22:15 +0000)
committerJeff Peeler <jpeeler@digium.com>
Wed, 6 May 2009 22:15:19 +0000 (22:15 +0000)
Just changed park_exec to always return non-zero. I really wasn't entirely sure
at first if this was a bug. Decided it was since it would be surprising when
not using ParkedCall in the dialplan to hang up and have dialplan execution
continue.

(closes issue #14555)
Reported by: francesco_r

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

res/res_features.c

index e2f1810a936e61ede72e84c3965552f2a84788e6..00bacaa936db386636d66eedc7b4fbdfaaf43647 100644 (file)
@@ -2575,7 +2575,7 @@ static int park_exec(struct ast_channel *chan, void *data)
                /* Simulate the PBX hanging up */
                ast_hangup(peer);
                ast_module_user_remove(u);
-               return res;
+               return -1;
        } else {
                /*! \todo XXX Play a message XXX */
                if (ast_stream_and_wait(chan, "pbx-invalidpark", chan->language, ""))
@@ -2587,7 +2587,7 @@ static int park_exec(struct ast_channel *chan, void *data)
 
        ast_module_user_remove(u);
 
-       return res;
+       return -1;
 }
 
 static int handle_showfeatures(int fd, int argc, char *argv[])