]> git.ipfire.org Git - thirdparty/haproxy.git/commit
MINOR: hlua_fcn: wrap pat_ref struct for patref class
authorAurelien DARRAGON <adarragon@haproxy.com>
Tue, 19 Nov 2024 14:34:11 +0000 (15:34 +0100)
committerAurelien DARRAGON <adarragon@haproxy.com>
Fri, 29 Nov 2024 06:22:54 +0000 (07:22 +0100)
commit43ab25f007ba2a29d7c0fda694d6831aafad33a0
tree85e46ac03d92184568d8804cb7301a8eac3cdd94
parent202107239103a98fbf643d90d3f2dcaa6fb66927
MINOR: hlua_fcn: wrap pat_ref struct for patref class

In order to extend the patref class features, let's wrap the pat_ref struct
into hlua_patref struct. This way we may add additional data alongside the
pat_ref pointer to store additional context required for pat_ref data
manipulation from lua.

Since the wrapper (hlua_patref) is an allocated object, we declare the _gc
metamethod for patref class in order to properly cleanup resources when
they are out of scope.
include/haproxy/hlua-t.h
src/hlua_fcn.c