diff --git a/mozilla/layout/generic/nsLineLayout.cpp b/mozilla/layout/generic/nsLineLayout.cpp index a6bcc32969d..97021b1dd3a 100644 --- a/mozilla/layout/generic/nsLineLayout.cpp +++ b/mozilla/layout/generic/nsLineLayout.cpp @@ -952,8 +952,9 @@ nsLineLayout::ReflowFrame(nsIFrame* aFrame, if (inTextControl) { nsLineBox *currentLine=nsnull; - nsresult rv = nsBlockFrame::GetCurrentLine(mBlockRS, ¤tLine); - if (NS_SUCCEEDED(rv) && currentLine) { + // use localResult because a failure here should not be propagated to my caller + nsresult localResult = nsBlockFrame::GetCurrentLine(mBlockRS, ¤tLine); + if (NS_SUCCEEDED(localResult) && currentLine) { currentLine->SetForceInvalidate(PR_TRUE); } } diff --git a/mozilla/layout/html/base/src/nsLineLayout.cpp b/mozilla/layout/html/base/src/nsLineLayout.cpp index a6bcc32969d..97021b1dd3a 100644 --- a/mozilla/layout/html/base/src/nsLineLayout.cpp +++ b/mozilla/layout/html/base/src/nsLineLayout.cpp @@ -952,8 +952,9 @@ nsLineLayout::ReflowFrame(nsIFrame* aFrame, if (inTextControl) { nsLineBox *currentLine=nsnull; - nsresult rv = nsBlockFrame::GetCurrentLine(mBlockRS, ¤tLine); - if (NS_SUCCEEDED(rv) && currentLine) { + // use localResult because a failure here should not be propagated to my caller + nsresult localResult = nsBlockFrame::GetCurrentLine(mBlockRS, ¤tLine); + if (NS_SUCCEEDED(localResult) && currentLine) { currentLine->SetForceInvalidate(PR_TRUE); } }