diff options
Diffstat (limited to 'lib/parse_ini.c')
-rw-r--r-- | lib/parse_ini.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/parse_ini.c b/lib/parse_ini.c index 57e60942..0cc864ae 100644 --- a/lib/parse_ini.c +++ b/lib/parse_ini.c | |||
@@ -131,7 +131,7 @@ np_get_defaults(const char *locator, const char *default_section) | |||
131 | if (inifile == NULL) | 131 | if (inifile == NULL) |
132 | die(STATE_UNKNOWN, _("Can't read config file: %s\n"), | 132 | die(STATE_UNKNOWN, _("Can't read config file: %s\n"), |
133 | strerror(errno)); | 133 | strerror(errno)); |
134 | if (read_defaults(inifile, i.stanza, &defaults) == FALSE) | 134 | if (!read_defaults(inifile, i.stanza, &defaults)) |
135 | die(STATE_UNKNOWN, | 135 | die(STATE_UNKNOWN, |
136 | _("Invalid section '%s' in config file '%s'\n"), i.stanza, | 136 | _("Invalid section '%s' in config file '%s'\n"), i.stanza, |
137 | i.file); | 137 | i.file); |
@@ -157,7 +157,8 @@ np_get_defaults(const char *locator, const char *default_section) | |||
157 | static int | 157 | static int |
158 | read_defaults(FILE *f, const char *stanza, np_arg_list **opts) | 158 | read_defaults(FILE *f, const char *stanza, np_arg_list **opts) |
159 | { | 159 | { |
160 | int c, status = FALSE; | 160 | int c = 0; |
161 | bool status = false; | ||
161 | size_t i, stanza_len; | 162 | size_t i, stanza_len; |
162 | enum { NOSTANZA, WRONGSTANZA, RIGHTSTANZA } stanzastate = NOSTANZA; | 163 | enum { NOSTANZA, WRONGSTANZA, RIGHTSTANZA } stanzastate = NOSTANZA; |
163 | 164 | ||
@@ -219,7 +220,7 @@ read_defaults(FILE *f, const char *stanza, np_arg_list **opts) | |||
219 | die(STATE_UNKNOWN, "%s\n", | 220 | die(STATE_UNKNOWN, "%s\n", |
220 | _("Config file error")); | 221 | _("Config file error")); |
221 | } | 222 | } |
222 | status = TRUE; | 223 | status = true; |
223 | break; | 224 | break; |
224 | } | 225 | } |
225 | break; | 226 | break; |