]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
deal with empty param to serialize()
authorAnthony Minessale <anthm@freeswitch.org>
Mon, 12 Jul 2010 20:37:07 +0000 (15:37 -0500)
committerAnthony Minessale <anthm@freeswitch.org>
Mon, 12 Jul 2010 20:37:16 +0000 (15:37 -0500)
libs/esl/src/esl_oop.cpp

index 1b6629c066be55d1d484ef6c3c64e4b323ca12bf..231950f892e9bb7cbc7fa9446808721462dc9d25 100644 (file)
@@ -355,7 +355,7 @@ const char *ESLevent::serialize(const char *format)
                return "";
        }
 
-       if (!strcasecmp(format, "json")) {
+       if (format && !strcasecmp(format, "json")) {
                esl_event_serialize_json(event, &serialized_string);
                return serialized_string;
        }