jscript: Fixed typo in to_integer.
This commit is contained in:
parent
898cb6fcd4
commit
dff4f0b598
|
@ -358,7 +358,7 @@ HRESULT to_integer(script_ctx_t *ctx, VARIANT *v, jsexcept_t *ei, VARIANT *ret)
|
||||||
return hres;
|
return hres;
|
||||||
|
|
||||||
if(V_VT(&num) == VT_I4)
|
if(V_VT(&num) == VT_I4)
|
||||||
*ret = *v;
|
*ret = num;
|
||||||
else
|
else
|
||||||
num_set_val(ret, V_R8(&num) >= 0.0 ? floor(V_R8(&num)) : -floor(-V_R8(&num)));
|
num_set_val(ret, V_R8(&num) >= 0.0 ? floor(V_R8(&num)) : -floor(-V_R8(&num)));
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue