MINOR: arg: Use chunk_destroy() to release string arguments
authorChristopher Faulet <cfaulet@haproxy.com>
Fri, 7 Aug 2020 09:45:18 +0000 (11:45 +0200)
committerChristopher Faulet <cfaulet@haproxy.com>
Fri, 11 Sep 2020 08:10:41 +0000 (10:10 +0200)
commit72231480ccebc9ad6c9a7ac83e172018dc96f62e
tree27c659502accfec27067b68d2c4c5fd6b1282e1c
parentd109ed649ba0afa14db5601d1f316f8b2e47dc4a
MINOR: arg: Use chunk_destroy() to release string arguments

This way, all fields of the buffer structure are reset when a string argument
(ARGT_STR) is released.  It is also a good way to explicitly specify this kind
of argument is a chunk. So .data and .size fields must be set.

This patch may be backported to ease backports.

(cherry picked from commit 6ad7df423b71470babef545506a1af569074fc59)
Signed-off-by: Willy Tarreau <w@1wt.eu>
(cherry picked from commit 1c67ab418b2adfd99e0c9d2796af382a86ce4a0f)
Signed-off-by: Christopher Faulet <cfaulet@haproxy.com>
src/acl.c
src/hlua.c
src/map.c
src/payload.c
src/proto_tcp.c
src/sample.c