[svn-commits] kpfleming: trunk r89704 - in /trunk: ./ main/app.c

SVN commits to the Digium repositories svn-commits at lists.digium.com
Tue Nov 27 13:47:19 CST 2007


Author: kpfleming
Date: Tue Nov 27 13:47:19 2007
New Revision: 89704

URL: http://svn.digium.com/view/asterisk?view=rev&rev=89704
Log:
Merged revisions 89701 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r89701 | kpfleming | 2007-11-27 13:36:55 -0600 (Tue, 27 Nov 2007) | 2 lines

generate a warning when an application option that requires an argument is ignored due to lack of an argument

........

Modified:
    trunk/   (props changed)
    trunk/main/app.c

Propchange: trunk/
------------------------------------------------------------------------------
Binary property 'branch-1.4-merged' - no diff available.

Modified: trunk/main/app.c
URL: http://svn.digium.com/view/asterisk/trunk/main/app.c?view=diff&rev=89704&r1=89703&r2=89704
==============================================================================
--- trunk/main/app.c (original)
+++ trunk/main/app.c Tue Nov 27 13:47:19 2007
@@ -1624,8 +1624,11 @@
 		} else if (argloc) {
 			args[argloc - 1] = NULL;
 		}
-		if (!argloc || !ast_strlen_zero(args[argloc - 1]))
-			ast_set_flag(flags, options[curarg].flag);
+		if (argloc && ast_strlen_zero(args[argloc - 1])) {
+			ast_log(LOG_WARNING, "Argument supplied for option '%c' was empty, option ignored.\n", curarg);
+			continue;
+		}
+		ast_set_flag(flags, options[curarg].flag);
 	}
 
 	return res;




More information about the svn-commits mailing list