]> pilppa.org Git - uci.git/blobdiff - file.c
some extra null pointer checks
[uci.git] / file.c
diff --git a/file.c b/file.c
index 4b607f803aa283b8baa77caeb547f7a9fc65ca6d..416422d6182e08d0d5aa45f621b6a12bf2891ce2 100644 (file)
--- a/file.c
+++ b/file.c
@@ -453,6 +453,9 @@ static void uci_parse_line(struct uci_context *ctx, bool single)
                char *pbrk = NULL;
                word = strtok_r(word, " \t", &pbrk);
 
+               if (!word)
+                       continue;
+
                switch(word[0]) {
                        case '#':
                                return;