[webkit-reviews] review denied: [Bug 50331] ASSERT failing restoring scroll position from HistoryItem after reload : [Attachment 75704] Patch proposal + unit test

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Dec 29 18:01:03 PST 2010


Darin Adler <darin at apple.com> has denied Mario Sanchez Prada
<msanchez at igalia.com>'s request for review:
Bug 50331: ASSERT failing restoring scroll position from HistoryItem after
reload
https://bugs.webkit.org/show_bug.cgi?id=50331

Attachment 75704: Patch proposal + unit test
https://bugs.webkit.org/attachment.cgi?id=75704&action=review

------- Additional Comments from Darin Adler <darin at apple.com>
View in context: https://bugs.webkit.org/attachment.cgi?id=75704&action=review

Thanks for tackling this.

> WebCore/loader/FrameLoader.cpp:2410
> +	       // If the user had a scroll point, scroll to it, overriding the
anchor
> +	       // point if any. Also, make sure there's a valid current item in
the
> +	       // history before trying to scroll because it could happen there
was
> +	       // none (e.g. loading from a string instead of an URI).
> +	       if (m_frame->page() && history()->currentItem()) {
>		   if (isBackForwardLoadType(m_loadType) || m_loadType ==
FrameLoadTypeReload || m_loadType == FrameLoadTypeReloadFromOrigin)
>		       history()->restoreScrollPositionAndViewState();
>	       }

It’s pretty clear looking at this code that the currentItem check belongs
inside the restoreScrollPositionAndViewState function, not here at the call
site.


More information about the webkit-reviews mailing list