mirror of
https://github.com/tmate-io/tmate.git
synced 2024-12-26 00:29:46 +01:00
Reset cfg_ncauses to 0 as well or we could allocate the wrong size if
called again.
This commit is contained in:
parent
91f6347485
commit
b7777e7ef3
2
cfg.c
2
cfg.c
@ -140,6 +140,7 @@ cfg_print_causes(struct cmd_q *cmdq)
|
|||||||
|
|
||||||
free(cfg_causes);
|
free(cfg_causes);
|
||||||
cfg_causes = NULL;
|
cfg_causes = NULL;
|
||||||
|
cfg_ncauses = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
@ -161,4 +162,5 @@ cfg_show_causes(struct session *s)
|
|||||||
|
|
||||||
free(cfg_causes);
|
free(cfg_causes);
|
||||||
cfg_causes = NULL;
|
cfg_causes = NULL;
|
||||||
|
cfg_ncauses = 0;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user