From 7329787b9a536d0dc9304677ea8980882e2cfe05 Mon Sep 17 00:00:00 2001 From: Anthony Minessale Date: Wed, 3 Oct 2012 07:45:39 -0500 Subject: [PATCH] fix warning --- src/mod/applications/mod_commands/mod_commands.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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);