зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1451908 - Check for infinite value in txFormatNumberFunctionCall. r=peterv a=abillings
This commit is contained in:
Родитель
8489323f79
Коммит
ec9d567f14
|
@ -271,6 +271,12 @@ txFormatNumberFunctionCall::evaluate(txIEvalContext* aContext,
|
|||
aResult);
|
||||
}
|
||||
|
||||
// Make sure the multiplier didn't push value to infinity.
|
||||
if (value == mozilla::PositiveInfinity<double>()) {
|
||||
return aContext->recycler()->getStringResult(format->mInfinity,
|
||||
aResult);
|
||||
}
|
||||
|
||||
// Prefix
|
||||
nsAutoString res(prefix);
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче