[asterisk-commits] file: trunk r92365 - /trunk/res/res_monitor.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Tue Dec 11 14:06:44 CST 2007


Author: file
Date: Tue Dec 11 14:06:43 2007
New Revision: 92365

URL: http://svn.digium.com/view/asterisk?view=rev&rev=92365
Log:
Only look to see if options are set if some have been provided.
(closes issue #11505)
Reported by: Mike Anikienko

Modified:
    trunk/res/res_monitor.c

Modified: trunk/res/res_monitor.c
URL: http://svn.digium.com/view/asterisk/trunk/res/res_monitor.c?view=diff&rev=92365&r1=92364&r2=92365
==============================================================================
--- trunk/res/res_monitor.c (original)
+++ trunk/res/res_monitor.c Tue Dec 11 14:06:43 2007
@@ -458,14 +458,16 @@
 	parse = ast_strdupa((char*)data);
 	AST_STANDARD_APP_ARGS(args, parse);
 
-	if (strchr(args.options, 'm'))
-		stream_action |= X_JOIN;
-	if (strchr(args.options, 'b'))
-		waitforbridge = 1;
-	if (strchr(args.options, 'i'))
-		stream_action &= ~X_REC_IN;
-	if (strchr(args.options, 'o'))
-		stream_action &= ~X_REC_OUT;
+	if (!ast_strlen_zero(args.options)) {
+		if (strchr(args.options, 'm'))
+			stream_action |= X_JOIN;
+		if (strchr(args.options, 'b'))
+			waitforbridge = 1;
+		if (strchr(args.options, 'i'))
+			stream_action &= ~X_REC_IN;
+		if (strchr(args.options, 'o'))
+			stream_action &= ~X_REC_OUT;
+	}
 
 	arg = strchr(args.format, ':');
 	if (arg) {




More information about the asterisk-commits mailing list