summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStef Walter <stef@memberwebs.com>2006-02-23 23:42:33 +0000
committerStef Walter <stef@memberwebs.com>2006-02-23 23:42:33 +0000
commit3a157c679247b95057a2d1260241429baf0c55e0 (patch)
treeaa6d625aeeeb3fb99660a8439b5b6d99d78a5640
parent3020535895a92836e327832b42200c599a485db7 (diff)
Fail properly when reading a config file failed.
-rw-r--r--common/config-parser.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/common/config-parser.c b/common/config-parser.c
index f303abe..23f57a4 100644
--- a/common/config-parser.c
+++ b/common/config-parser.c
@@ -125,6 +125,9 @@ cfg_parse_file(const char* filename, void* data, char** memory)
ASSERT(filename);
config = read_config_file(filename, data);
+ if(!config)
+ goto finally;
+
next = config;
/* Go through lines and process them */