[asterisk-commits] qwell: branch 1.8 r364841 - /branches/1.8/main/manager.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Tue May 1 16:37:21 CDT 2012


Author: qwell
Date: Tue May  1 16:37:17 2012
New Revision: 364841

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=364841
Log:
Prevent a potential crash when using manager hooks.

Found by me while poking at DPMA-127.

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=364841&r1=364840&r2=364841
==============================================================================
--- branches/1.8/main/manager.c (original)
+++ branches/1.8/main/manager.c Tue May  1 16:37:17 2012
@@ -4070,7 +4070,7 @@
 		format = 0;
 		ast_parse_allow_disallow(NULL, &format, codecs, 1);
 	}
-	if (!ast_strlen_zero(app)) {
+	if (!ast_strlen_zero(app) && s->session) {
 		int bad_appdata = 0;
 		/* To run the System application (or anything else that goes to
 		 * shell), you must have the additional System privilege */




More information about the asterisk-commits mailing list