From: Anthony Minessale Date: Wed, 3 Oct 2012 12:45:39 +0000 (-0500) Subject: fix warning X-Git-Tag: v1.3.0~122 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7329787b9a536d0dc9304677ea8980882e2cfe05;p=thirdparty%2Ffreeswitch.git fix warning --- diff --git a/src/mod/applications/mod_commands/mod_commands.c b/src/mod/applications/mod_commands/mod_commands.c index 38e85a47c2..f1a9953fde 100644 --- a/src/mod/applications/mod_commands/mod_commands.c +++ b/src/mod/applications/mod_commands/mod_commands.c @@ -299,7 +299,7 @@ SWITCH_STANDARD_API(version_function) argc = switch_separate_string(mydata, ' ', argv, (sizeof(argv) / sizeof(argv[0]))); - if (argv[0] && switch_stristr("short", argv[0])) { + if (argc > 0 && switch_stristr("short", argv[0])) { stream->write_function(stream, "%s.%s.%s\n", SWITCH_VERSION_MAJOR,SWITCH_VERSION_MINOR,SWITCH_VERSION_MICRO); } else { stream->write_function(stream, "FreeSWITCH Version %s (%s)\n", SWITCH_VERSION_FULL, SWITCH_VERSION_FULL_HUMAN);