luainstance: work around a signed/unsigned problem on ppc

This commit is contained in:
Stefan Seyfried
2013-04-06 19:06:46 +02:00
committed by M. Liebmann
parent ef512f897a
commit 8af79e1152

View File

@@ -374,7 +374,8 @@ int CLuaInstance::PaintBox(lua_State *L)
y = luaL_checkint(L, 3); y = luaL_checkint(L, 3);
w = luaL_checkint(L, 4); w = luaL_checkint(L, 4);
h = luaL_checkint(L, 5); h = luaL_checkint(L, 5);
c = luaL_checkint(L, 6); /* luaL_checkint does not like e.g. 0xffcc0000 on powerpc (returns INT_MAX) instead */
c = (unsigned int)luaL_checknumber(L, 6);
if (count > 6) if (count > 6)
radius = luaL_checkint(L, 7); radius = luaL_checkint(L, 7);
if (count > 7) if (count > 7)