Minor code style cleanup. Fix a couple compiler warnings.

--HG--
branch : minor
This commit is contained in:
Alex Szpakowski
2016-12-03 17:23:46 -04:00
parent 7d68a72d5f
commit 8e2d9c5138
3 changed files with 30 additions and 28 deletions
+2 -2
View File
@@ -347,7 +347,7 @@ int w_Source_setFilter(lua_State *L)
else if (lua_gettop(L) > 2)
{
const char *ftypestr = luaL_checkstring(L, 2);
if (ftypestr && !Filter::getConstant(ftypestr, type))
if (!Filter::getConstant(ftypestr, type))
return luaL_error(L, "Invalid filter type: %s", ftypestr);
unsigned int count = Filter::getParameterCount(type);
@@ -363,7 +363,7 @@ int w_Source_setFilter(lua_State *L)
}
lua_rawgeti(L, 2, 1);
const char *ftypestr = luaL_checkstring(L, -1);
if (ftypestr && !Filter::getConstant(ftypestr, type))
if (!Filter::getConstant(ftypestr, type))
return luaL_error(L, "Invalid filter type: %s", ftypestr);
lua_pop(L, 1);