[asterisk-commits] kmoore: branch 1.8 r331315 - /branches/1.8/main/manager.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Wed Aug 10 08:47:49 CDT 2011


Author: kmoore
Date: Wed Aug 10 08:47:46 2011
New Revision: 331315

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=331315
Log:
AMI action ModuleReload returns Error if Module: missing or empty

An empty string was not being checked for properly causing identification of
the module to be reloaded to fail and return an Error with message
"No such module."

(closes issue AST-616)

Modified:
    branches/1.8/main/manager.c

Modified: branches/1.8/main/manager.c
URL: http://svnview.digium.com/svn/asterisk/branches/1.8/main/manager.c?view=diff&rev=331315&r1=331314&r2=331315
==============================================================================
--- branches/1.8/main/manager.c (original)
+++ branches/1.8/main/manager.c Wed Aug 10 08:47:46 2011
@@ -4439,7 +4439,7 @@
 			astman_send_ack(s, m, "Module unloaded.");
 		}
 	} else if (!strcasecmp(loadtype, "reload")) {
-		if (module != NULL) {
+		if (!ast_strlen_zero(module)) {
 			res = ast_module_reload(module);
 			if (res == 0) {
 				astman_send_error(s, m, "No such module.");




More information about the asterisk-commits mailing list