mirror of
https://github.com/haproxy/haproxy.git
synced 2026-06-28 02:30:51 -04:00
Add a registration mechanism so that modules outside of hlua.c can hook into each lua_State creation. Modules call hap_register_hlua_state_init() (or the REGISTER_HLUA_STATE_INIT() macro) with a callback of the form: int my_init(lua_State *L, char **errmsg); The callback returns an ERR_* code. ERR_ALERT and ERR_WARN trigger ha_alert()/ha_warning() respectively; any other non-zero errmsg is emitted via ha_notice(). ERR_FATAL or ERR_ABORT cause exit(1). Registered entries are freed in hlua_deinit(). |
||
|---|---|---|
| .. | ||
| haproxy | ||
| import | ||
| make | ||