From: Anthony Minessale Date: Thu, 2 Jul 2009 00:18:56 +0000 (+0000) Subject: sleep_eat_digits var (behaviour change please document) X-Git-Tag: v1.0.4~265 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2f3f67f050ba55467eed6120ff8a6763e8998677;p=thirdparty%2Ffreeswitch.git sleep_eat_digits var (behaviour change please document) git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@14102 d0543943-73ff-0310-b7d9-9358b9ac24b2 --- diff --git a/src/mod/applications/mod_dptools/mod_dptools.c b/src/mod/applications/mod_dptools/mod_dptools.c index c950bfe0d6..7e2309b515 100644 --- a/src/mod/applications/mod_dptools/mod_dptools.c +++ b/src/mod/applications/mod_dptools/mod_dptools.c @@ -1415,11 +1415,12 @@ SWITCH_STANDARD_APP(sleep_function) char buf[10]; switch_input_args_t args = { 0 }; - args.input_callback = on_dtmf; - args.buf = buf; - args.buflen = sizeof(buf); - - switch_channel_set_variable(channel, SWITCH_PLAYBACK_TERMINATOR_USED, "" ); + if (switch_true(switch_channel_get_variable(channel, "sleep_eat_digits"))) { + args.input_callback = on_dtmf; + args.buf = buf; + args.buflen = sizeof(buf); + switch_channel_set_variable(channel, SWITCH_PLAYBACK_TERMINATOR_USED, "" ); + } switch_ivr_sleep(session, ms, SWITCH_TRUE, &args); }