summaryrefslogtreecommitdiffstats
path: root/cfg.c
diff options
context:
space:
mode:
authornicm <nicm>2015-04-27 22:50:35 +0000
committernicm <nicm>2015-04-27 22:50:35 +0000
commitb7777e7ef37a6a5b9a231602c1ac66a307ae23db (patch)
treea14e8609bede018fff74ee7907154ef1d2673d5a /cfg.c
parent91f6347485a2efe714cf0bc50e4d1fbc2a33c01e (diff)
Reset cfg_ncauses to 0 as well or we could allocate the wrong size if
called again.
Diffstat (limited to 'cfg.c')
-rw-r--r--cfg.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/cfg.c b/cfg.c
index bacec996..8b44ce24 100644
--- a/cfg.c
+++ b/cfg.c
@@ -140,6 +140,7 @@ cfg_print_causes(struct cmd_q *cmdq)
free(cfg_causes);
cfg_causes = NULL;
+ cfg_ncauses = 0;
}
void
@@ -161,4 +162,5 @@ cfg_show_causes(struct session *s)
free(cfg_causes);
cfg_causes = NULL;
+ cfg_ncauses = 0;
}