diff --git a/layout/base/RestyleManager.cpp b/layout/base/RestyleManager.cpp index 004a61c5d16a..482b9612c181 100644 --- a/layout/base/RestyleManager.cpp +++ b/layout/base/RestyleManager.cpp @@ -3076,6 +3076,13 @@ RestyleManager::ComputeAndProcessStyleChange(nsIFrame* aFrame, RestyleTracker& aRestyleTracker, nsRestyleHint aRestyleHint) { + // Create a ReframingStyleContexts struct on the stack and put it in + // our mReframingStyleContexts for the scope of this function. + MOZ_ASSERT(!mReframingStyleContexts, "shouldn't call recursively"); + AutoRestore ar(mReframingStyleContexts); + ReframingStyleContexts reframingStyleContexts; + mReframingStyleContexts = &reframingStyleContexts; + nsStyleChangeList changeList; ComputeStyleChangeFor(aFrame, &changeList, aMinChange, aRestyleTracker, aRestyleHint);