Author: anonymissimus
Date: Sun Aug 7 16:51:04 2011
New Revision: 50639
URL: http://svn.gna.org/viewcvs/wesnoth?rev=50639&view=rev
Log:
fix an MSVC warning about converting from lua_number to int (possible data loss)
Modified:
trunk/src/ai/lua/lua_object.hpp
Modified: trunk/src/ai/lua/lua_object.hpp
URL:
http://svn.gna.org/viewcvs/wesnoth/trunk/src/ai/lua/lua_object.hpp?rev=50639&r1=50638&r2=50639&view=diff
==============================================================================
--- trunk/src/ai/lua/lua_object.hpp (original)
+++ trunk/src/ai/lua/lua_object.hpp Sun Aug 7 16:51:04 2011
@@ -108,7 +108,7 @@
template <>
inline boost::shared_ptr<int> lua_object<int>::to_type(lua_State *L, int n)
{
- return boost::shared_ptr<int>(new int(lua_tonumber(L, n)));
+ return boost::shared_ptr<int>(new int(lua_tointeger(L, n)));
}
template <>
_______________________________________________
Wesnoth-commits mailing list
[email protected]
https://mail.gna.org/listinfo/wesnoth-commits