mirror of
https://github.com/apache/httpd.git
synced 2025-08-08 15:02:10 +03:00
Support building against Lua 5.4 by adjusting to the 3-arg form of
lua_resume(). * modules/lua/config.m4 (CHECK_LUA): Check for lua5.4 paths. * modules/lua/mod_lua.c (lua_output_filter_handle, lua_input_filter_handle): Check that exactly one item is on the stack as indicated by lua_resume(). Submitted by: Lubos Uhliarik <luhliari redhat.com>, jorton PR: 64591 Github: closes #130, closes #133, closes #134 git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1880678 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
@@ -48,7 +48,15 @@
|
||||
#if LUA_VERSION_NUM > 501
|
||||
/* Load mode for lua_load() */
|
||||
#define lua_load(a,b,c,d) lua_load(a,b,c,d,NULL)
|
||||
#define lua_resume(a,b) lua_resume(a, NULL, b)
|
||||
|
||||
#if LUA_VERSION_NUM > 503
|
||||
#define lua_resume(a,b,c) lua_resume(a, NULL, b, c)
|
||||
#else
|
||||
/* ### For version < 5.4, assume that exactly one stack item is on the
|
||||
* stack, which is what the code did before but seems dubious. */
|
||||
#define lua_resume(a,b,c) (*(c) = 1, lua_resume(a, NULL, b))
|
||||
#endif
|
||||
|
||||
#define luaL_setfuncs_compat(a,b) luaL_setfuncs(a,b,0)
|
||||
#else
|
||||
#define lua_rawlen(L,i) lua_objlen(L, (i))
|
||||
|
Reference in New Issue
Block a user