mirror of
https://github.com/lua/lua.git
synced 2026-06-08 08:03:49 +00:00
Avoid macros luaL_loadbuffer and luaL_loadfile
Use luaL_loadbufferx and luaL_loadfilex instead, being explicit about whether to accept binary chunks.
This commit is contained in:
@@ -874,7 +874,7 @@ LUALIB_API int luaL_loadbufferx (lua_State *L, const char *buff, size_t size,
|
||||
|
||||
|
||||
LUALIB_API int luaL_loadstring (lua_State *L, const char *s) {
|
||||
return luaL_loadbuffer(L, s, strlen(s), s);
|
||||
return luaL_loadbufferx(L, s, strlen(s), s, "t");
|
||||
}
|
||||
|
||||
/* }====================================================== */
|
||||
|
||||
Reference in New Issue
Block a user