diff options
author | Llewelyn Trahaearn | 2017-05-26 21:25:08 -0700 |
---|---|---|
committer | Llewelyn Trahaearn | 2017-05-26 21:25:08 -0700 |
commit | 037feb15a9a69faf95f07df9fef893e220998dbc (patch) | |
tree | 2f1876adca4beba212f8971f3ac3f4593c5b2b7a /fix-saturated_arithmetic.patch | |
download | aur-037feb15a9a69faf95f07df9fef893e220998dbc.tar.gz |
Initial commit: Resources added to the AUR.
Diffstat (limited to 'fix-saturated_arithmetic.patch')
-rw-r--r-- | fix-saturated_arithmetic.patch | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/fix-saturated_arithmetic.patch b/fix-saturated_arithmetic.patch new file mode 100644 index 000000000000..f9a18220a99b --- /dev/null +++ b/fix-saturated_arithmetic.patch @@ -0,0 +1,20 @@ +--- qtwebkit-2.3.4/Source/WTF/wtf/SaturatedArithmetic.h 2014-09-24 13:42:05.000000000 +0200 ++++ qtwebkit-2.3.4/Source/WTF/wtf/SaturatedArithmetic.h 2017-02-19 16:27:58.343676787 +0100 +@@ -43,7 +43,7 @@ + + // Can only overflow if the signed bit of the two values match. If the signed + // bit of the result and one of the values differ it did overflow. +- if (!((ua ^ ub) >> 31) & (result ^ ua) >> 31) ++ if (~((ua ^ ub) >> 31) & ((result ^ ua) >> 31)) + result = std::numeric_limits<int>::max() + (ua >> 31); + + return result; +@@ -57,7 +57,7 @@ + + // Can only overflow if the signed bit of the two values do not match. If the + // signed bit of the result and the first value differ it did overflow. +- if ((ua ^ ub) >> 31 & (result ^ ua) >> 31) ++ if (((ua ^ ub) >> 31) & ((result ^ ua) >> 31)) + result = std::numeric_limits<int>::max() + (ua >> 31); + + return result; |