]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
Skinny: avoid crash when loading config with blank soft-key-set value
authorMathieu Parent <math.parent@gmail.com>
Thu, 24 Feb 2011 22:53:53 +0000 (23:53 +0100)
committerMathieu Parent <math.parent@gmail.com>
Thu, 24 Feb 2011 23:05:56 +0000 (00:05 +0100)
src/mod/endpoints/mod_skinny/mod_skinny.c

index 46acdb6bacaaa4baffa6da1fa795c2326c33d7b4..4061b945185dd875fb5f364ca20ea95e4d91185c 100644 (file)
@@ -1811,6 +1811,9 @@ static switch_status_t load_skinny_config(void)
                                                                        size_t string_len = strlen(val);
                                                                        size_t string_pos, start = 0;
                                                                        int field_no = 0;
+                                                                       if (zstr(val)) {
+                                                                               continue;
+                                                                       }
                                                                        if (soft_key_set_id > 15) {
                                                                                switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_WARNING,
                                                                                        "soft-key-set name '%s' is greater than 15 in soft-key-set-set '%s' in profile %s.\n",