screen: use checkudata()
Signed-off-by: Julien Danjou <julien@danjou.info>
This commit is contained in:
parent
cd862e80cd
commit
e02384e4fe
5
screen.c
5
screen.c
|
@ -366,10 +366,7 @@ static int
|
||||||
luaA_screen_tags(lua_State *L)
|
luaA_screen_tags(lua_State *L)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
screen_t *s = lua_touserdata(L, 1);
|
screen_t *s = luaL_checkudata(L, 1, "screen");
|
||||||
|
|
||||||
if(!s)
|
|
||||||
luaL_typerror(L, 1, "screen");
|
|
||||||
|
|
||||||
if(lua_gettop(L) == 2)
|
if(lua_gettop(L) == 2)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue