]> git.ipfire.org Git - thirdparty/haproxy.git/commit
MINOR: lua: Get the action return code on the stack when an action finishes
authorChristopher Faulet <cfaulet@haproxy.com>
Wed, 29 Jan 2020 10:53:30 +0000 (11:53 +0100)
committerChristopher Faulet <cfaulet@haproxy.com>
Thu, 6 Feb 2020 14:13:03 +0000 (15:13 +0100)
commit7716cdf450b8a18780f359cb3fd2127609ffb2df
treeb4c1f7c0c07d2b61f590d8ca24f022d4d6b9a480
parenta20a653e07a063e79fa934b12375a882df7996f2
MINOR: lua: Get the action return code on the stack when an action finishes

When an action successfully finishes, the action return code (ACT_RET_*) is now
retrieve on the stack, ff the first element is an integer. In addition, in
hlua_txn_done(), the value ACT_RET_DONE is pushed on the stack before
exiting. Thus, when a script uses this function, the corresponding action still
finishes with the good code. Thanks to this change, the flag HLUA_STOP is now
useless. So it has been removed.

It is a mandatory step to allow a lua action to return any action return code.
include/types/hlua.h
src/hlua.c