Commit 04f7ec69 authored by Richard M. Stallman's avatar Richard M. Stallman

(Fmod): Fix the final adjustment, when i2 < 0 and i1 == 0.

parent 75c70425
......@@ -1951,7 +1951,7 @@ Both X and Y must be numbers or markers.")
i1 %= i2;
/* If the "remainder" comes out with the wrong sign, fix it. */
if ((i1 < 0) != (i2 < 0))
if (i2 < 0 ? i1 > 0 : i1 < 0)
i1 += i2;
XSETINT (val, i1);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment