BUG/MINOR: hlua: Fix memory leaks on error path when registering an action
authorChristopher Faulet <cfaulet@haproxy.com>
Mon, 12 Apr 2021 13:08:12 +0000 (15:08 +0200)
committerChristopher Faulet <cfaulet@haproxy.com>
Mon, 12 Apr 2021 17:04:42 +0000 (19:04 +0200)
commit4fc9da01d21469ab137cf5607753640485a82fe7
tree85dab6d256d32b4f25b039c8305584609c355076
parent528526f2ccf6fac0c8755545e814094fe7f76d16
BUG/MINOR: hlua: Fix memory leaks on error path when registering an action

When an error occurred in hlua_register_action(), the allocated lua function
and keyword must be released to avoid memory leaks.

This patch depends on "MINOR: hlua: Add function to release a lua
function". It may be backported in all stable versions.
src/hlua.c