mirror of
https://github.com/love2d/love.git
synced 2026-08-16 00:02:12 +02:00
Fixed undefined behaviour when love exceptions are converted into Lua errors (resolves issue #729)
This commit is contained in:
@@ -40,7 +40,7 @@ int w_FrictionJoint_setMaxForce(lua_State *L)
|
||||
{
|
||||
FrictionJoint *t = luax_checkfrictionjoint(L, 1);
|
||||
float arg1 = (float)luaL_checknumber(L, 2);
|
||||
ASSERT_GUARD(t->setMaxForce(arg1);)
|
||||
EXCEPT_GUARD(t->setMaxForce(arg1);)
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -55,7 +55,7 @@ int w_FrictionJoint_setMaxTorque(lua_State *L)
|
||||
{
|
||||
FrictionJoint *t = luax_checkfrictionjoint(L, 1);
|
||||
float arg1 = (float)luaL_checknumber(L, 2);
|
||||
ASSERT_GUARD(t->setMaxTorque(arg1);)
|
||||
EXCEPT_GUARD(t->setMaxTorque(arg1);)
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user