From 330c3f12de62d1df54f80b014cc0b911c0d0cb20 Mon Sep 17 00:00:00 2001 From: Jeff Peeler Date: Mon, 4 Jan 2010 16:27:48 +0000 Subject: [PATCH] Merged revisions 237323 via svnmerge from https://origsvn.digium.com/svn/asterisk/trunk ........ r237323 | jpeeler | 2010-01-04 10:24:51 -0600 (Mon, 04 Jan 2010) | 5 lines Fix timeout for AGI command speech recognize. (closes issue #16297) Reported by: semond ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.2@237326 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- res/res_agi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/res/res_agi.c b/res/res_agi.c index b63f4debea..410357aef6 100644 --- a/res/res_agi.c +++ b/res/res_agi.c @@ -2212,7 +2212,7 @@ static int handle_speechrecognize(struct ast_channel *chan, AGI *agi, int argc, switch (speech->state) { case AST_SPEECH_STATE_READY: /* If the stream is done, start timeout calculation */ - if ((timeout > 0) && ((!chan->stream) || (chan->streamid == -1 && chan->timingfunc == NULL))) { + if ((timeout > 0) && start == 0 && ((!chan->stream) || (chan->streamid == -1 && chan->timingfunc == NULL))) { ast_stopstream(chan); time(&start); }