Bug 1258017 - Cleanup fixes for trunk. r=me
authorBobby Holley <bobbyholley@gmail.com>
Thu, 21 Apr 2016 13:53:04 -0700
changeset 332257 1f597dfdd06acb64209d81985e40b2c3207bd984
parent 332256 65a3c56652e5ce0730d3e2bcac2b0ebe95c6c158
child 332258 c45842dc546821416db290899802ca22cb9a703d
push id6048
push userkmoir@mozilla.com
push dateMon, 06 Jun 2016 19:02:08 +0000
treeherdermozilla-beta@46d72a56c57d [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersme
bugs1258017
milestone48.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1258017 - Cleanup fixes for trunk. r=me
layout/base/crashtests/crashtests.list
layout/reftests/font-face/reftest.list
layout/style/nsStyleContext.cpp
layout/style/nsStyleSet.cpp
--- a/layout/base/crashtests/crashtests.list
+++ b/layout/base/crashtests/crashtests.list
@@ -289,17 +289,17 @@ load 468578-1.xhtml
 # browser does when setting up print preview, but adding them anyway.
 load 468645-1.xhtml
 load 468645-2.xhtml
 load 468645-3.xhtml
 load 469861-1.xhtml
 load 469861-2.xhtml
 load 470851-1.xhtml
 load 471594-1.xhtml
-asserts-if(Android&&!asyncPan,2) load 473042.xhtml # bug 1034369 (may also cause a few assertions to be registered on the next test)
+asserts-if(Android&&!asyncPan,1-2) load 473042.xhtml # bug 1034369 (may also cause a few assertions to be registered on the next test)
 asserts(0-5) load 474075.html # bug 847368
 load 477333-1.xhtml
 load 477731-1.html
 load 479114-1.html
 load 479360-1.xhtml
 load 480686-1.html
 load 481806-1.html
 load 483604-1.xhtml
--- a/layout/reftests/font-face/reftest.list
+++ b/layout/reftests/font-face/reftest.list
@@ -2,17 +2,17 @@
 # ../fonts/.  We can't use file:/// URLs because of cross-directory access
 # restrictions on file: URLs.
 
 HTTP(..) != download-1.html download-1-notref.html
 HTTP(..) == download-2.html download-2-ref.html
 HTTP(..) != download-2.html about:blank
 random-if(winWidget) HTTP(..) == download-2-big.html download-2-big-otf.html # bug 470713
 HTTP(..) != download-2-big-otf.html about:blank
-asserts-if(Android&&!asyncPan,4-8) HTTP(..) != download-3-notref.html download-3.html # bug 1019192
+asserts-if(Android&&!asyncPan,1-8) HTTP(..) != download-3-notref.html download-3.html # bug 1019192
 asserts-if(Android,0-8) HTTP(..) == download-3-ref.html download-3.html # same bugs as above
 asserts-if(Android,0-8) HTTP(..) == fallback-to-system-1.html fallback-to-system-1-ref.html # just delayed assertions from above tests
 HTTP(..) == name-override-simple-1.html name-override-simple-1-ref.html
 HTTP(..) != name-override-simple-1.html download-1-notref.html
 fails HTTP(..) == name-override-1.html name-override-1-ref.html
 HTTP(..) == multiple-descriptor-1.html multiple-descriptor-1-ref.html
 HTTP(..) != multiple-descriptor-1.html multiple-descriptor-1-notref.html
 HTTP(..) == src-list-1.html src-list-1-ref.html
--- a/layout/style/nsStyleContext.cpp
+++ b/layout/style/nsStyleContext.cpp
@@ -187,20 +187,20 @@ nsStyleContext::~nsStyleContext()
     // In DEBUG builds when the pref is not enabled, we perform a more limited
     // check just of the children of this style context.
     AssertStructsNotUsedElsewhere(this, 2);
   }
 #endif
 
   nsPresContext *presContext = PresContext();
   DebugOnly<nsStyleSet*> geckoStyleSet = presContext->PresShell()->StyleSet()->GetAsGecko();
-  MOZ_ASSERT(!geckoStyleSet ||
-             geckoStyleSet->GetRuleTree() == mSource.AsGeckoRuleNode()->RuleTree() ||
-             geckoStyleSet->IsInRuleTreeReconstruct(),
-             "destroying style context from old rule tree too late");
+  NS_ASSERTION(!geckoStyleSet ||
+               geckoStyleSet->GetRuleTree() == mSource.AsGeckoRuleNode()->RuleTree() ||
+               geckoStyleSet->IsInRuleTreeReconstruct(),
+               "destroying style context from old rule tree too late");
 
   if (mParent) {
     mParent->RemoveChild(this);
   } else {
     presContext->StyleSet()->RootStyleContextRemoved();
   }
 
   // Free up our data structs.
--- a/layout/style/nsStyleSet.cpp
+++ b/layout/style/nsStyleSet.cpp
@@ -2205,17 +2205,20 @@ nsStyleSet::GCRuleTrees()
     if (node == mOldRootNode) {
       // Flag that we've GCed the old root, if any.
       mOldRootNode = nullptr;
     }
 #endif
     node->Destroy();
   }
 
-  MOZ_ASSERT(!mOldRootNode, "Should have GCed old root node");
+#ifdef DEBUG
+  NS_ASSERTION(!mOldRootNode, "Should have GCed old root node");
+  mOldRootNode = nullptr;
+#endif
   mUnusedRuleNodeCount = 0;
   mInGC = false;
 }
 
 already_AddRefed<nsStyleContext>
 nsStyleSet::ReparentStyleContext(nsStyleContext* aStyleContext,
                                  nsStyleContext* aNewParentContext,
                                  Element* aElement)