From: Christopher Faulet Date: Wed, 26 Feb 2020 13:54:16 +0000 (+0100) Subject: MINOR: lua: Rename hlua_action_wake_time() to hlua_set_wake_time() X-Git-Tag: v2.2-dev4~30 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=501465d94bb30a69361abddf8f748e30aef258d3;p=thirdparty%2Fhaproxy.git MINOR: lua: Rename hlua_action_wake_time() to hlua_set_wake_time() This function does not depends on the action class. So use a more generic name. It will be easier to bind it on another class if necessary. --- diff --git a/src/hlua.c b/src/hlua.c index f1e91f5cc3..dda156dda6 100644 --- a/src/hlua.c +++ b/src/hlua.c @@ -6485,10 +6485,9 @@ __LJMP static int hlua_register_fetches(lua_State *L) return 0; } -/* This function is a lua binding to set the wake_time from an action. It is - * only used if the action return ACT_RET_YIELD. +/* This function is a lua binding to set the wake_time. */ -__LJMP static int hlua_action_wake_time(lua_State *L) +__LJMP static int hlua_set_wake_time(lua_State *L) { struct hlua *hlua = hlua_gethlua(L); unsigned int delay; @@ -8096,7 +8095,7 @@ void hlua_init(void) hlua_class_const_int(gL.T, "ABORT", ACT_RET_ABRT); hlua_class_const_int(gL.T, "INVALID", ACT_RET_INV); - hlua_class_function(gL.T, "wake_time", hlua_action_wake_time); + hlua_class_function(gL.T, "wake_time", hlua_set_wake_time); lua_setglobal(gL.T, "act");