CLEANUP: haproxy: Free post_server_check_list in deinit()

This allocation is technically always reachable and cannot leak, but so are
a few others that *are* freed.
This commit is contained in:
Tim Duesterhus 2020-07-04 11:49:50 +02:00 committed by Willy Tarreau
parent 0837eb11cf
commit 34bef074c6

View File

@ -2607,6 +2607,7 @@ void deinit(void)
struct post_deinit_fct *pdf, *pdfb; struct post_deinit_fct *pdf, *pdfb;
struct proxy_deinit_fct *pxdf, *pxdfb; struct proxy_deinit_fct *pxdf, *pxdfb;
struct server_deinit_fct *srvdf, *srvdfb; struct server_deinit_fct *srvdf, *srvdfb;
struct post_server_check_fct *pscf, *pscfb;
deinit_signals(); deinit_signals();
while (p) { while (p) {
@ -2907,6 +2908,11 @@ void deinit(void)
free(srvdf); free(srvdf);
} }
list_for_each_entry_safe(pscf, pscfb, &post_server_check_list, list) {
LIST_DEL(&pscf->list);
free(pscf);
}
vars_prune(&global.vars, NULL, NULL); vars_prune(&global.vars, NULL, NULL);
pool_destroy_all(); pool_destroy_all();
deinit_pollers(); deinit_pollers();