mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-26 06:11:37 +00:00
Bug 1275449 - Part 1: AnimationEffectTiming::SetEasing crash in page-mode addon context. r=hiro
MozReview-Commit-ID: DeyC4BiXJNo --HG-- extra : transplant_source : %AE6%85a_%96%F6%A0%E3%3B%20g%07%14%CF%8F%F2%CA%D7o
This commit is contained in:
parent
15abb6f63e
commit
4471abc361
@ -134,10 +134,14 @@ AnimationEffectTiming::SetEasing(JSContext* aCx,
|
||||
const nsAString& aEasing,
|
||||
ErrorResult& aRv)
|
||||
{
|
||||
nsIDocument* document = AnimationUtils::GetCurrentRealmDocument(aCx);
|
||||
if (!document) {
|
||||
aRv.Throw(NS_ERROR_FAILURE);
|
||||
return;
|
||||
}
|
||||
|
||||
Maybe<ComputedTimingFunction> newFunction =
|
||||
TimingParams::ParseEasing(aEasing,
|
||||
AnimationUtils::GetCurrentRealmDocument(aCx),
|
||||
aRv);
|
||||
TimingParams::ParseEasing(aEasing, document, aRv);
|
||||
if (aRv.Failed()) {
|
||||
return;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user