From fffb60d1ca5b8ecee88f6586a01de49165fd2de5 Mon Sep 17 00:00:00 2001 From: Anthony Minessale Date: Thu, 3 Apr 2008 20:01:59 +0000 Subject: [PATCH] enforce wait/nowait arg on out git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@8009 d0543943-73ff-0310-b7d9-9358b9ac24b2 --- src/mod/applications/mod_fifo/mod_fifo.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/mod/applications/mod_fifo/mod_fifo.c b/src/mod/applications/mod_fifo/mod_fifo.c index fbcec3a965..974e9e4f90 100644 --- a/src/mod/applications/mod_fifo/mod_fifo.c +++ b/src/mod/applications/mod_fifo/mod_fifo.c @@ -233,7 +233,12 @@ SWITCH_STANDARD_APP(fifo_function) announce = switch_channel_get_variable(channel, "fifo_announce"); if (argc > 2) { - nowait = !strcasecmp(argv[2], "nowait"); + if (!strcasecmp(argv[2], "nowait")) { + nowait++; + } else if (strcasecmp(argv[2], "wait")) { + switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "USAGE %s\n", FIFO_USAGE); + return; + } } if (!strcasecmp(argv[1], "in")) {