[asterisk-commits] kpfleming: trunk r276441 - /trunk/main/loader.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Wed Jul 14 15:15:59 CDT 2010


Author: kpfleming
Date: Wed Jul 14 15:15:48 2010
New Revision: 276441

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=276441
Log:
Don't try to call an embedded module's backup_globals() function until
after confirming it exists.


Modified:
    trunk/main/loader.c

Modified: trunk/main/loader.c
URL: http://svnview.digium.com/svn/asterisk/trunk/main/loader.c?view=diff&rev=276441&r1=276440&r2=276441
==============================================================================
--- trunk/main/loader.c (original)
+++ trunk/main/loader.c Wed Jul 14 15:15:48 2010
@@ -836,7 +836,7 @@
 		return required ? AST_MODULE_LOAD_FAILURE : AST_MODULE_LOAD_DECLINE;
 	}
 
-	if (!mod->lib && mod->info->backup_globals()) {
+	if (!mod->lib && mod->info->backup_globals && mod->info->backup_globals()) {
 		ast_log(LOG_WARNING, "Module '%s' was unable to backup its global data.\n", resource_name);
 		return required ? AST_MODULE_LOAD_FAILURE : AST_MODULE_LOAD_DECLINE;
 	}




More information about the asterisk-commits mailing list