summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAurelien DARRAGON <adarragon@haproxy.com>2023-05-11 12:36:32 +0200
committerChristopher Faulet <cfaulet@haproxy.com>2023-05-11 15:37:04 +0200
commit8dfc2491d2e3a511246f570e0de86c253a86ec54 (patch)
tree433191d84ffbf7a96f944a6cf0fc045b02c3fdd3
parent7542fb43d6d1803252c409a20192d97dec19328b (diff)
downloadhaproxy-8dfc2491d2e3a511246f570e0de86c253a86ec54.tar.gz
BUG/MINOR: proxy: missing free in free_proxy for redirect rules
cookie_str from struct redirect, which may be allocated through http_parse_redirect_rule() function is not properly freed on proxy cleanup within free_proxy(). This could be backported to all stable versions. [for 2.2, free_proxy() did not exist so the fix needs to be performed directly in deinit() function from haproxy.c]
-rw-r--r--src/proxy.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/proxy.c b/src/proxy.c
index b614e345b..af37b4492 100644
--- a/src/proxy.c
+++ b/src/proxy.c
@@ -243,6 +243,7 @@ void free_proxy(struct proxy *p)
free(rdr->cond);
}
free(rdr->rdr_str);
+ free(rdr->cookie_str);
list_for_each_entry_safe(lf, lfb, &rdr->rdr_fmt, list) {
LIST_DELETE(&lf->list);
release_sample_expr(lf->expr);