Bug 163389

Summary: [GTK] WebKitWebPage URI not updated after URI is modified by InjectedBundlePageResourceLoadClient::willSendRequestForFrame
Product: WebKit Reporter: Michael Catanzaro <mcatanzaro>
Component: WebKitGTKAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: bugs-noreply, cgarcia, mcatanzaro
Priority: P2    
Version: Other   
Hardware: PC   
OS: Linux   
Bug Depends on: 146306, 163436    
Bug Blocks:    
Attachments:
Description Flags
Patch mcatanzaro: review+

Description Michael Catanzaro 2016-10-13 08:57:44 PDT
InjectedBundlePageResourceLoadClient::willSendRequestForFrame() allows clients to modify the ResourceRequest passed to it. We rely on this in the GTK+ API in order to allow a web extension to modify URLs before they are loaded. F

Our WebKitWebPage's URI property is not updated when this happens. Follow-up to bug #146306.
Comment 1 Carlos Garcia Campos 2016-10-14 02:40:23 PDT
Created attachment 291603 [details]
Patch
Comment 2 Michael Catanzaro 2016-10-14 11:34:36 PDT
(In reply to comment #0)
> InjectedBundlePageResourceLoadClient::willSendRequestForFrame() allows
> clients to modify the ResourceRequest passed to it. We rely on this in the
> GTK+ API in order to allow a web extension to modify URLs before they are
> loaded. F

F? What were you thinking, myself?
Comment 3 Michael Catanzaro 2016-10-14 11:40:34 PDT
Comment on attachment 291603 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=291603&action=review

> Tools/TestWebKitAPI/Tests/WebKit2Gtk/TestLoaderClient.cpp:408
> +    void loadURI(const char* uri)

Eventually we should start using override in our unit test classes.
Comment 4 Carlos Garcia Campos 2016-10-16 02:14:08 PDT
Committed r207389: <http://trac.webkit.org/changeset/207389>