From fdbe96d9c6fc8c7d151b036d1015559aa4f91611 Mon Sep 17 00:00:00 2001 From: rtri Date: Wed, 7 Dec 2016 13:30:16 +0100 Subject: [PATCH] fix #5404 --- rts/Lua/LuaSyncedMoveCtrl.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rts/Lua/LuaSyncedMoveCtrl.cpp b/rts/Lua/LuaSyncedMoveCtrl.cpp index 44233fbe826..f1a2491655c 100644 --- a/rts/Lua/LuaSyncedMoveCtrl.cpp +++ b/rts/Lua/LuaSyncedMoveCtrl.cpp @@ -548,8 +548,8 @@ static int SetMoveTypeData(lua_State* L, AMoveType* moveType, const char* caller { int numAssignedValues = 0; - if (moveType == NULL) { - luaL_error(L, "[%s] unit %d has incompatible movetype for %s", __FUNCTION__, lua_tonumber(L, 1), caller); + if (moveType == nullptr) { + luaL_error(L, "[%s] unit %d has incompatible movetype for %s", __FUNCTION__, lua_tointeger(L, 1), caller); return numAssignedValues; }