Fix crash when scrolling absolute positioned textarea by adding test to return value from |GetLine|. Bug 105004, r=rbs, sr=kin

git-svn-id: svn://10.0.0.236/trunk@108261 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
smontagu%netscape.com
2001-11-16 03:08:30 +00:00
parent 70829fcf48
commit 1dc588ab2f
2 changed files with 4 additions and 0 deletions

View File

@@ -3737,6 +3737,8 @@ nsFrame::GetFrameFromDirection(nsIPresContext* aPresContext, nsPeekOffsetStruct
&lineFlags);
if (NS_FAILED(result))
return result;
if (!firstFrame)
return NS_ERROR_FAILURE;
lastFrame = firstFrame;
for (;lineFrameCount > 1;lineFrameCount --){

View File

@@ -3737,6 +3737,8 @@ nsFrame::GetFrameFromDirection(nsIPresContext* aPresContext, nsPeekOffsetStruct
&lineFlags);
if (NS_FAILED(result))
return result;
if (!firstFrame)
return NS_ERROR_FAILURE;
lastFrame = firstFrame;
for (;lineFrameCount > 1;lineFrameCount --){