[Webkit-unassigned] [Bug 139342] Pending API Request URL is wrong after reloading

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Feb 2 04:02:25 PST 2016


https://bugs.webkit.org/show_bug.cgi?id=139342

--- Comment #4 from Carlos Garcia Campos <cgarcia at igalia.com> ---
(In reply to comment #3)
> Comment on attachment 242716 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=242716&action=review
> 
> I’m saying review+ but I am not 100% sure this is right.
> 
> > Source/WebKit2/UIProcess/WebPageProxy.cpp:902
> > +    String url = m_pageLoadState.activeURL();
> > +    if (url.isEmpty() && m_backForwardList->currentItem())
> > +        url = m_backForwardList->currentItem()->url();
> > +
> > +    if (!url.isEmpty()) {
> 
> Seems a little peculiar here to use isEmpty rather than isNull.
> 
> I’m generally concerned that this code is trying to figure out what URL the
> other process will reload; we are not sending the URL over, so this is
> trying to predict what the other process will do? If so, then it seems that
> to be correct this has to match the logic in FrameLoader::reload and other
> loader logic inside WebCore, and it seems to me that adding this one thing
> it’s still far from matching it!

Note that this only affects the pending API request URL. This is to ensure that getting the active URL right after load or reload returns a valid URL, in case of load methods the one passed to the load. In case of reload that URL should always be the current active URL of the web view, since that's what we want to reload. If the web process ends up loading a different URL it doesn't really matter, because as soon as provisional load starts, the provisional url is used  instead of the pending api request one.

> It’s nice to fix this one particular case,
> but what about:
> 
> - The case where there is an unreachableURL.

This case is covered by this patch, because PageLoadState::activeURL() returns the unreachable URL if there's one.

> - If a window is created by javascript, its main frame can have an empty but
> non-nil URL. We need to test that case.

Yes, I would need to check what happens in this particular case.

> I’d like to hear Anders’s opinion.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-unassigned/attachments/20160202/d620d422/attachment-0001.html>


More information about the webkit-unassigned mailing list