From 60586abc93e119ef6cc48189b21e2588017887b3 Mon Sep 17 00:00:00 2001 From: Kees Monshouwer Date: Mon, 19 Jan 2015 10:18:53 +0100 Subject: [PATCH] use luaL_checkinteger for Lua 5.3 --- pdns/lua-auth.cc | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pdns/lua-auth.cc b/pdns/lua-auth.cc index 8010ed2ad..4e977ae30 100644 --- a/pdns/lua-auth.cc +++ b/pdns/lua-auth.cc @@ -131,7 +131,11 @@ static DNSPacket* ldp_checkDNSPacket(lua_State *L) { static int ldp_setRcode(lua_State *L) { DNSPacket *p=ldp_checkDNSPacket(L); +#if LUA_VERSION_NUM < 503 int rcode = luaL_checkint(L, 2); +#else + int rcode = (int)luaL_checkinteger(L, 2); +#endif p->setRcode(rcode); return 0; } -- 2.40.0