CLEANUP: deinit: release the config postparsers
These ones were not released either, it just requires to export the list
("postparsers") and it makes valgrind happy.
diff --git a/include/haproxy/cfgparse.h b/include/haproxy/cfgparse.h
index 2708f76..7c3d128 100644
--- a/include/haproxy/cfgparse.h
+++ b/include/haproxy/cfgparse.h
@@ -88,6 +88,7 @@
int (*func)();
};
+extern struct list postparsers;
extern int cfg_maxpconn;
extern int cfg_maxconn;
extern char *cfg_scope;
diff --git a/src/haproxy.c b/src/haproxy.c
index 4ae694e..02690ed 100644
--- a/src/haproxy.c
+++ b/src/haproxy.c
@@ -2558,6 +2558,7 @@
struct post_check_fct *pcf, *pcfb;
struct post_proxy_check_fct *ppcf, *ppcfb;
struct pre_check_fct *prcf, *prcfb;
+ struct cfg_postparser *pprs, *pprsb;
int cur_fd;
/* At this point the listeners state is weird:
@@ -2738,6 +2739,11 @@
free(tff);
}
+ list_for_each_entry_safe(pprs, pprsb, &postparsers, list) {
+ LIST_DELETE(&pprs->list);
+ free(pprs);
+ }
+
vars_prune(&proc_vars, NULL, NULL);
pool_destroy_all();
deinit_pollers();