aboutsummaryrefslogtreecommitdiffstats
path: root/res
diff options
context:
space:
mode:
authortilghman <tilghman@f38db490-d61c-443f-a65b-d21fe96a405b>2009-05-04 19:31:33 +0000
committertilghman <tilghman@f38db490-d61c-443f-a65b-d21fe96a405b>2009-05-04 19:31:33 +0000
commit86849e1951c5359980955ed796e7e7d6402f4590 (patch)
treed5c8c9e4b9bf7ebe21adf13da6cdced73fcbeba0 /res
parent1a7f76fbc7b8ade491570d26cc4b5cb01777fbe5 (diff)
Merged revisions 192171 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk ........ r192171 | tilghman | 2009-05-04 14:29:13 -0500 (Mon, 04 May 2009) | 8 lines Restore 'asyncagi break' command to 1.6.1 and higher. (closes issue #14985) Reported by: nikkk Patches: 20090428__bug14985.diff.txt uploaded by tilghman (license 14) 20090429__bug14985__1.6.1.diff.txt uploaded by tilghman (license 14) Tested by: nikkk ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@192173 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'res')
-rw-r--r--res/res_agi.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/res/res_agi.c b/res/res_agi.c
index efd8549b3..1018bf4eb 100644
--- a/res/res_agi.c
+++ b/res/res_agi.c
@@ -78,6 +78,19 @@ ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
<ref type="agi">hangup</ref>
</see-also>
</agi>
+ <agi name="asyncagi break" language="en_US">
+ <synopsis>
+ Interrupts Async AGI
+ </synopsis>
+ <syntax />
+ <description>
+ <para>Interrupts expected flow of Async AGI commands and returns control to previous source
+ (typically, the PBX dialplan).</para>
+ </description>
+ <see-also>
+ <ref type="agi">hangup</ref>
+ </see-also>
+ </agi>
<agi name="channel status" language="en_US">
<synopsis>
Returns status of the connected channel.
@@ -1018,6 +1031,12 @@ static int handle_answer(struct ast_channel *chan, AGI *agi, int argc, char *arg
return (res >= 0) ? RESULT_SUCCESS : RESULT_FAILURE;
}
+static int handle_asyncagi_break(struct ast_channel *chan, AGI *agi, int argc, char *argv[])
+{
+ ast_agi_send(agi->fd, chan, "200 result=0\n");
+ return RESULT_FAILURE;
+}
+
static int handle_waitfordigit(struct ast_channel *chan, AGI *agi, int argc, char *argv[])
{
int res, to;
@@ -2449,6 +2468,7 @@ static char usage_speechrecognize[] =
*/
static struct agi_command commands[] = {
{ { "answer", NULL }, handle_answer, NULL, NULL, 0 },
+ { { "asyncagi", "break", NULL }, handle_asyncagi_break, NULL, NULL, 1 },
{ { "channel", "status", NULL }, handle_channelstatus, NULL, NULL, 0 },
{ { "database", "del", NULL }, handle_dbdel, NULL, NULL, 1 },
{ { "database", "deltree", NULL }, handle_dbdeltree, NULL, NULL, 1 },