From 4b2877834e5438868427eee5cfe333369724743b Mon Sep 17 00:00:00 2001 From: Mark Spencer Date: Thu, 2 Sep 2004 03:32:07 +0000 Subject: [PATCH] Fix threeway calling + immediate mode (bug #2344) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@3705 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- channels/chan_zap.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/channels/chan_zap.c b/channels/chan_zap.c index ac0c268dee..a061712edf 100755 --- a/channels/chan_zap.c +++ b/channels/chan_zap.c @@ -4760,7 +4760,12 @@ static void *ss_thread(void *data) if (p->subs[SUB_THREEWAY].owner) timeout = 999999; while(len < AST_MAX_EXTENSION-1) { - res = ast_waitfordigit(chan, timeout); + /* Read digit unless it's supposed to be immediate, in which case the + only answer is 's' */ + if (p->immediate) + res = 's'; + else + res = ast_waitfordigit(chan, timeout); timeout = 0; if (res < 0) { ast_log(LOG_DEBUG, "waitfordigit returned < 0...\n"); -- 2.47.2