From 41510454a8cb65b62b98a30bf5512416d1c7217f Mon Sep 17 00:00:00 2001 From: Michael Jerris Date: Fri, 16 May 2008 16:15:37 +0000 Subject: [PATCH] don't pass null to switch_loadable_module_get_api_interface. Found by Klockwork (www.klocwork.com) git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@8439 d0543943-73ff-0310-b7d9-9358b9ac24b2 --- src/switch_loadable_module.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/switch_loadable_module.c b/src/switch_loadable_module.c index 1c64030933..d592a35da6 100644 --- a/src/switch_loadable_module.c +++ b/src/switch_loadable_module.c @@ -1349,7 +1349,7 @@ SWITCH_DECLARE(switch_status_t) switch_api_execute(const char *cmd, const char * } } - if ((api = switch_loadable_module_get_api_interface(cmd)) != 0) { + if (cmd && (api = switch_loadable_module_get_api_interface(cmd)) != 0) { status = api->function(arg, session, stream); } else { status = SWITCH_STATUS_FALSE;