Bug 1153478 - Part 2: Remove useless assertions. r=roc, a=sledru
--- a/layout/generic/nsContainerFrame.cpp
+++ b/layout/generic/nsContainerFrame.cpp
@@ -1632,17 +1632,16 @@ nsContainerFrame::MoveOverflowToChildLis
return DrainSelfOverflowList() || result;
}
bool
nsContainerFrame::DrainSelfOverflowList()
{
AutoFrameListPtr overflowFrames(PresContext(), StealOverflowFrames());
if (overflowFrames) {
- NS_ASSERTION(mFrames.NotEmpty(), "overflow list w/o frames");
mFrames.AppendFrames(nullptr, *overflowFrames);
return true;
}
return false;
}
nsIFrame*
nsContainerFrame::GetNextInFlowChild(ContinuationTraversingState& aState,
--- a/layout/generic/nsInlineFrame.cpp
+++ b/layout/generic/nsInlineFrame.cpp
@@ -502,17 +502,16 @@ nsInlineFrame::AttributeChanged(int32_t
}
bool
nsInlineFrame::DrainSelfOverflowListInternal(DrainFlags aFlags,
nsIFrame* aLineContainer)
{
AutoFrameListPtr overflowFrames(PresContext(), StealOverflowFrames());
if (overflowFrames) {
- NS_ASSERTION(mFrames.NotEmpty(), "overflow list w/o frames");
// The frames on our own overflowlist may have been pushed by a
// previous lazilySetParentPointer Reflow so we need to ensure the
// correct parent pointer. This is sometimes skipped by Reflow.
if (!(aFlags & eDontReparentFrames)) {
nsIFrame* firstChild = overflowFrames->FirstChild();
if (aLineContainer && aLineContainer->GetPrevContinuation()) {
ReparentFloatsForInlineChild(aLineContainer, firstChild, true);
}
@@ -1194,18 +1193,16 @@ nsFirstLineFrame::PullOverflowsFromPrevI
}
}
/* virtual */ bool
nsFirstLineFrame::DrainSelfOverflowList()
{
AutoFrameListPtr overflowFrames(PresContext(), StealOverflowFrames());
if (overflowFrames) {
- NS_ASSERTION(mFrames.NotEmpty(), "overflow list w/o frames");
-
bool result = !overflowFrames->IsEmpty();
const nsFrameList::Slice& newFrames =
mFrames.AppendFrames(nullptr, *overflowFrames);
ReparentChildListStyle(PresContext(), newFrames, this);
return result;
}
return false;
}