patch-xpcom_ds_nsMathUtils_h 675 B

123456789101112131415161718192021
  1. --- mozilla-release.orig/xpcom/ds/nsMathUtils.h 2015-01-09 05:38:29.000000000 +0100
  2. +++ mozilla-release/xpcom/ds/nsMathUtils.h 2015-01-29 21:37:27.000000000 +0100
  3. @@ -104,12 +104,16 @@ NS_finite(double aNum)
  4. #ifdef WIN32
  5. // NOTE: '!!' casts an int to bool without spamming MSVC warning C4800.
  6. return !!_finite(aNum);
  7. -#elif defined(XP_DARWIN)
  8. +#elif defined(XP_DARWIN) || defined(__UCLIBC__)
  9. // Darwin has deprecated |finite| and recommends |isfinite|. The former is
  10. // not present in the iOS SDK.
  11. return std::isfinite(aNum);
  12. #else
  13. - return finite(aNum);
  14. +#ifdef _GLIBCXX_CMATH
  15. + return std::isfinite(d);
  16. +#else
  17. + return isfinite(d);
  18. +#endif
  19. #endif
  20. }