From 128f3bdbbf35845ec2af59d488a7d291ea8e0ba8 Mon Sep 17 00:00:00 2001 From: "blakeross%telocity.com" Date: Mon, 5 Mar 2001 22:09:14 +0000 Subject: [PATCH] Table crash in webmail page (70072). r=karnaze sr=attinasi --- layout/html/table/src/nsTableFrame.cpp | 2 +- layout/tables/nsTableFrame.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/layout/html/table/src/nsTableFrame.cpp b/layout/html/table/src/nsTableFrame.cpp index f77c6dcebfe..9647c300ccb 100644 --- a/layout/html/table/src/nsTableFrame.cpp +++ b/layout/html/table/src/nsTableFrame.cpp @@ -4320,7 +4320,7 @@ nsTableFrame::GetFrameAtOrBefore(nsIPresContext* aPresContext, nsIFrame* childFrame; nsIFrame* lastMatchingFrame = nsnull; aParentFrame->FirstChild(aPresContext, nsnull, &childFrame); - while (childFrame != aPriorChildFrame) { + while (childFrame && childFrame != aPriorChildFrame) { childFrame->GetFrameType(&frameType); if (aChildType == frameType) { lastMatchingFrame = childFrame; diff --git a/layout/tables/nsTableFrame.cpp b/layout/tables/nsTableFrame.cpp index f77c6dcebfe..9647c300ccb 100644 --- a/layout/tables/nsTableFrame.cpp +++ b/layout/tables/nsTableFrame.cpp @@ -4320,7 +4320,7 @@ nsTableFrame::GetFrameAtOrBefore(nsIPresContext* aPresContext, nsIFrame* childFrame; nsIFrame* lastMatchingFrame = nsnull; aParentFrame->FirstChild(aPresContext, nsnull, &childFrame); - while (childFrame != aPriorChildFrame) { + while (childFrame && childFrame != aPriorChildFrame) { childFrame->GetFrameType(&frameType); if (aChildType == frameType) { lastMatchingFrame = childFrame;