summaryrefslogtreecommitdiff
path: root/layout/style/nsComputedDOMStyle.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'layout/style/nsComputedDOMStyle.cpp')
-rw-r--r--layout/style/nsComputedDOMStyle.cpp9
1 files changed, 8 insertions, 1 deletions
diff --git a/layout/style/nsComputedDOMStyle.cpp b/layout/style/nsComputedDOMStyle.cpp
index b3c4ccc148..65f42805de 100644
--- a/layout/style/nsComputedDOMStyle.cpp
+++ b/layout/style/nsComputedDOMStyle.cpp
@@ -6647,7 +6647,14 @@ nsComputedDOMStyle::DoGetAnimationIterationCount()
RefPtr<nsROCSSPrimitiveValue> iterationCount = new nsROCSSPrimitiveValue;
float f = animation->GetIterationCount();
- float inf = NS_IEEEPositiveInfinity();
+ /* Need a nasty hack here to work around an optimizer bug in gcc
+ 4.2 on Mac, which somehow gets confused when directly comparing
+ a float to the return value of NS_IEEEPositiveInfinity when
+ building 32-bit builds. */
+#ifdef XP_MACOSX
+ volatile
+#endif
+ float inf = NS_IEEEPositiveInfinity();
if (f == inf) {
iterationCount->SetIdent(eCSSKeyword_infinite);
} else {