]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
fixing commit a7108411233058511c59227617e446f28384dbd0 in switch_config
authorWilliam King <william.king@quentustech.com>
Mon, 28 Apr 2014 15:46:48 +0000 (08:46 -0700)
committerWilliam King <william.king@quentustech.com>
Mon, 28 Apr 2014 15:46:48 +0000 (08:46 -0700)
Previous commit actually broke the functionality since it was now returning if cfg->path[0] was not null.
Also since cfg->path can never be null, this check can be simplified to only check the first index.

src/switch_config.c

index 96999ad1e26ca6273782c66e668f16ec75b65aa2..93fcfad7ade3c5d47875a5ac6cc2e85dbcafc3a8 100644 (file)
@@ -105,7 +105,7 @@ SWITCH_DECLARE(int) switch_config_next_pair(switch_config_t *cfg, char **var, ch
 
        *var = *val = NULL;
 
-       if ( !cfg->path || (cfg->path && cfg->path[0] != '\0' )) {
+       if ( !cfg->path[0] ){
                return 0;
        }