Skip to content

Commit

Permalink
Fix segfault in config_parse_file
Browse files Browse the repository at this point in the history
configfile is a `char *`. %s needs a `char *`, so we shouldn't
dereference the pointer here.

Closes: #91
  • Loading branch information
emersion authored and danshick committed Mar 4, 2021
1 parent 07154bb commit d3ac33a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/core/config.c
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ static char *config_path(char *prefix, char *filename) {
static void config_parse_file(const char *configfile, struct xdpw_config *config) {
dictionary *d = NULL;
if (configfile) {
logprint(INFO, "config: using config file %s", *configfile);
logprint(INFO, "config: using config file %s", configfile);
d = iniparser_load(configfile);
} else {
logprint(INFO, "config: no config file found");
Expand Down

0 comments on commit d3ac33a

Please sign in to comment.