X-Git-Url: http://git.ozlabs.org/?p=petitboot;a=blobdiff_plain;f=discover%2Fparser-conf.c;h=4bd23871bc6e6980c2dc3d785de0eeb3bad27a74;hp=94612c326a6cdd35332443b1f5846878eafdd4fd;hb=30b2ac42df8827f2181c7294b2a628bbcc1cfef8;hpb=06a49ebdfc795a70b938f5aee29f3c488ef9fc21 diff --git a/discover/parser-conf.c b/discover/parser-conf.c index 94612c3..4bd2387 100644 --- a/discover/parser-conf.c +++ b/discover/parser-conf.c @@ -46,6 +46,9 @@ char *conf_strip_str(char *s) if (!s) return NULL; + if (!strlen(s)) + return NULL; + while (*s == '"' || *s == '\'' || isspace(*s)) s++;