Fix 32-bit mac opt bustage, bug 435442, r=dbaron

This commit is contained in:
Boris Zbarsky 2011-04-12 01:12:12 -07:00
parent 9757fe29e3
commit c55a85c955

View File

@ -4079,7 +4079,15 @@ nsComputedDOMStyle::DoGetAnimationIterationCount()
valueList->AppendCSSValue(iterationCount);
float f = animation->GetIterationCount();
if (f == 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 {
iterationCount->SetNumber(f);