mirror of
https://github.com/ZoiteChat/zoitechat.git
synced 2026-03-18 19:50:18 +00:00
lua: Use luaL_checkinteger
This commit is contained in:
@@ -600,7 +600,7 @@ static int api_timer_closure(void *udata)
|
|||||||
|
|
||||||
static int api_hexchat_hook_timer(lua_State *L)
|
static int api_hexchat_hook_timer(lua_State *L)
|
||||||
{
|
{
|
||||||
int ref, timeout = luaL_checknumber(L, 1);
|
int ref, timeout = luaL_checkinteger (L, 1);
|
||||||
hook_info *info, **u;
|
hook_info *info, **u;
|
||||||
|
|
||||||
lua_pushvalue(L, 2);
|
lua_pushvalue(L, 2);
|
||||||
@@ -985,7 +985,7 @@ static int api_attrs_meta_newindex(lua_State *L)
|
|||||||
char const *key = luaL_checkstring(L, 2);
|
char const *key = luaL_checkstring(L, 2);
|
||||||
if(!strcmp(key, "server_time_utc"))
|
if(!strcmp(key, "server_time_utc"))
|
||||||
{
|
{
|
||||||
attrs->server_time_utc = luaL_checknumber(L, 3);
|
attrs->server_time_utc = luaL_checkinteger(L, 3);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|||||||
Reference in New Issue
Block a user