diff options
author | Nicolas Pitre <nico@fluxnic.net> | 2021-03-21 23:13:05 -0400 |
---|---|---|
committer | Nicolas Pitre <nico@fluxnic.net> | 2021-03-22 01:24:17 -0400 |
commit | d76c7668fb509e2817e0ff95913eb28e2519f741 (patch) | |
tree | e9b702a78a0b48984cccccbf0cbcc2f6569d85b6 /src/conf.c | |
parent | 97ef9034c09326f850f726785d91ea67ca4cfa86 (diff) |
fix dictionary string parser
I didn't notice that multiple key=value pairs were possible in a single
string. Here's a new implementation that does it, with the ability to
parse the whole default_config string as well as command line args.
Diffstat (limited to 'src/conf.c')
-rw-r--r-- | src/conf.c | 7 |
1 files changed, 1 insertions, 6 deletions
@@ -107,12 +107,7 @@ const char default_config[] = // argument rather than using user_conf_d directly. void store_default_config_values() { - const char *line = default_config; - - do { - parse_str(user_conf_d, line, 0); - line = strchr(line, '\n'); - } while(line && *++line != 0); + parse_str(user_conf_d, default_config, 0); // Calculate GMT offset (not on Solaris, doesn't have tm_gmtoff) #if defined(USELOCALE) && !defined(__sun) |