aboutsummaryrefslogtreecommitdiffstats
path: root/main/xulrunner/0002-Use-C99-math-isfinite.patch
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2011-11-25 09:39:13 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2011-11-25 09:39:13 +0000
commitdbcdac2b6698e87c9dc04dca7621b533a22502b7 (patch)
treee6ce1daa4de04da905af591b4aad686af692a981 /main/xulrunner/0002-Use-C99-math-isfinite.patch
parent1693a44e16824ea7907bd8a045f54470fca2897e (diff)
downloadaports-dbcdac2b6698e87c9dc04dca7621b533a22502b7.tar.bz2
aports-dbcdac2b6698e87c9dc04dca7621b533a22502b7.tar.xz
main/xulrunner: upgrade to 8.0.1
Diffstat (limited to 'main/xulrunner/0002-Use-C99-math-isfinite.patch')
-rw-r--r--main/xulrunner/0002-Use-C99-math-isfinite.patch43
1 files changed, 43 insertions, 0 deletions
diff --git a/main/xulrunner/0002-Use-C99-math-isfinite.patch b/main/xulrunner/0002-Use-C99-math-isfinite.patch
new file mode 100644
index 0000000000..3d85a69288
--- /dev/null
+++ b/main/xulrunner/0002-Use-C99-math-isfinite.patch
@@ -0,0 +1,43 @@
+From cdb9db4c1c593dbe22db4f389a62fce034f31f2d Mon Sep 17 00:00:00 2001
+From: Natanael Copa <ncopa@alpinelinux.org>
+Date: Fri, 25 Nov 2011 08:30:51 +0000
+Subject: [PATCH 2/4] Use C99 math isfinite
+
+---
+ js/src/ctypes/CTypes.cpp | 2 +-
+ xpcom/ds/nsMathUtils.h | 6 +++++-
+ 2 files changed, 6 insertions(+), 2 deletions(-)
+
+diff --git a/js/src/ctypes/CTypes.cpp b/js/src/ctypes/CTypes.cpp
+index 5c0f886..a3b1ae6 100644
+--- a/js/src/ctypes/CTypes.cpp
++++ b/js/src/ctypes/CTypes.cpp
+@@ -467,7 +467,7 @@ static inline bool FloatIsFinite(jsdouble f) {
+ #ifdef WIN32
+ return _finite(f) != 0;
+ #else
+- return finite(f);
++ return isfinite(f);
+ #endif
+ }
+
+diff --git a/xpcom/ds/nsMathUtils.h b/xpcom/ds/nsMathUtils.h
+index 21ffbec..2e80476 100644
+--- a/xpcom/ds/nsMathUtils.h
++++ b/xpcom/ds/nsMathUtils.h
+@@ -131,7 +131,11 @@ inline NS_HIDDEN_(bool) NS_finite(double d)
+ // NOTE: '!!' casts an int to bool without spamming MSVC warning C4800.
+ return !!_finite(d);
+ #else
+- return finite(d);
++#ifdef _GLIBCXX_CMATH
++ return std::isfinite(d);
++#else
++ return isfinite(d);
++#endif
+ #endif
+ }
+
+--
+1.7.7.4
+