summaryrefslogtreecommitdiffstats
path: root/cfg.c
diff options
context:
space:
mode:
authornicm <nicm>2017-01-15 22:00:56 +0000
committernicm <nicm>2017-01-15 22:00:56 +0000
commit52847a951802fda7a3ce36cdac77c34914b0ccca (patch)
tree7e5ad465e719d32f2a7d9a7c3469dec6d12448a4 /cfg.c
parent30548461439f02ed8327f96748035685a1a26ace (diff)
It is silly for cmd_list_parse to return an integer error when it could
just return NULL.
Diffstat (limited to 'cfg.c')
-rw-r--r--cfg.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/cfg.c b/cfg.c
index 8424bb20..2be34fda 100644
--- a/cfg.c
+++ b/cfg.c
@@ -141,7 +141,8 @@ load_cfg(const char *path, struct client *c, struct cmdq_item *item, int quiet)
if (condition == -1)
continue;
- if (cmd_string_parse(p, &cmdlist, path, line, &cause1) != 0) {
+ cmdlist = cmd_string_parse(p, path, line, &cause1);
+ if (cmdlist == NULL) {
free(buf);
if (cause1 == NULL)
continue;