aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorxperia64 <xperiancedapps@gmail.com>2019-08-24 11:52:24 -0400
committerxperia64 <xperiancedapps@gmail.com>2019-08-24 11:52:24 -0400
commit6c7c037b202ca0e145a47a9d8dfbf34bc8cdda7d (patch)
tree77826c64776d51de618eb2514762df2e1de433ed
parent626a9c13859b556a19abbf2212233a834e11f022 (diff)
Fix division edge case
-rw-r--r--src/NDS.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/NDS.cpp b/src/NDS.cpp
index 991995d..ceeeb79 100644
--- a/src/NDS.cpp
+++ b/src/NDS.cpp
@@ -1416,7 +1416,7 @@ void DivDone(u32 param)
if (den == 0)
{
DivQuotient[0] = (num<0) ? 1:-1;
- DivQuotient[1] = (num<0) ? -1:1;
+ DivQuotient[1] = (num<0) ? -1:0;
*(s64*)&DivRemainder[0] = num;
}
else if (num == -0x80000000 && den == -1)