Bug 1401809 - Use Atom::from(nsIAtom) to increment reference count in case of dynamic atom for will-change. r=xidorn

If we don't increment the reference count for the Atom in servo side, it's
possible to try to release the Atom in servo side even if we have already
released in gecko side.  When it happens, nsIAtom::mKind is no longer reliable.

MozReview-Commit-ID: GrxbcYxowRB

--HG--
extra : rebase_source : 94e054e3357b31e398e8e5e81522dab3019c561c
This commit is contained in:
Hiroyuki Ikezoe 2017-09-21 15:50:37 +09:00
parent e7db2e5d36
commit 933ef2c9ba
2 changed files with 15 additions and 0 deletions

View File

@ -0,0 +1,14 @@
<html>
<head>
<style></style>
<script>
o1 = document.createElement('t');
document.documentElement.appendChild(o1);
document.styleSheets[0].insertRule('* { will-change:an }', 0);
k = new KeyframeEffect(o1, [{'willChange':'s'}], {'':''});
k = null;
SpecialPowers.forceGC();
SpecialPowers.forceCC();
</script>
</head>
</html>

View File

@ -33,3 +33,4 @@ pref(dom.animations-api.core.enabled,true) load 1373712-1.html
pref(dom.animations-api.core.enabled,true) load 1379606-1.html pref(dom.animations-api.core.enabled,true) load 1379606-1.html
pref(dom.animations-api.core.enabled,true) load 1393605-1.html pref(dom.animations-api.core.enabled,true) load 1393605-1.html
load 1400022-1.html load 1400022-1.html
pref(dom.animations-api.core.enabled,true) load 1401809.html