]> git.ipfire.org Git - thirdparty/nftables.git/commit
parser_bison: fix memory leaks on hookspec error processing
authorFlorian Westphal <fw@strlen.de>
Wed, 13 Dec 2023 10:18:06 +0000 (11:18 +0100)
committerFlorian Westphal <fw@strlen.de>
Wed, 13 Dec 2023 11:08:19 +0000 (12:08 +0100)
commitd755c2a3ae7fe8272321a1d81eafbd90052c4f14
treeea99407f68db393a0b8f59f0c09de6f87e6629d4
parent28b3bbec5a97aaa57f7138fee8b2f22ff0e5b960
parser_bison: fix memory leaks on hookspec error processing

prio_spec may contain an embedded expression, release it.
We also need to release the device expr and the hook string.

Signed-off-by: Florian Westphal <fw@strlen.de>
src/parser_bison.y
tests/shell/testcases/bogons/nft-f/memleak_on_hookspec_error [new file with mode: 0644]