Bug 184259

Summary: [SOUP] Stop using ResourceHandle to load GResources
Product: WebKit Reporter: Carlos Garcia Campos <cgarcia>
Component: PlatformAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: cdumez, dbates, ews-watchlist, japhet, svillar, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 184048    
Attachments:
Description Flags
Patch svillar: review+

Carlos Garcia Campos
Reported 2018-04-03 03:16:39 PDT
GResources are loaded in the WebProcess using ResourceHandle because soup handles them transparently. But now that we no longer use ResourceHandle, we can add a simple loader for GResources, similar to the one used for data URLS, since loading a GResource is a matter of calling g_resources_lookup_data() in the end.
Attachments
Patch (12.01 KB, patch)
2018-04-03 04:39 PDT, Carlos Garcia Campos
svillar: review+
Carlos Garcia Campos
Comment 1 2018-04-03 04:39:27 PDT
Sergio Villar Senin
Comment 2 2018-04-03 07:54:38 PDT
Comment on attachment 337068 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=337068&action=review > Source/WebCore/platform/glib/SharedBufferGlib.cpp:30 > +SharedBuffer::SharedBuffer(GBytes* bytes) I guess this can be a reference since it cannot be null. > Source/WebCore/platform/glib/SharedBufferGlib.cpp:37 > +Ref<SharedBuffer> SharedBuffer::create(GBytes* bytes) Ditto.
Carlos Garcia Campos
Comment 3 2018-04-03 08:06:40 PDT
(In reply to Sergio Villar Senin from comment #2) > Comment on attachment 337068 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=337068&action=review > > > Source/WebCore/platform/glib/SharedBufferGlib.cpp:30 > > +SharedBuffer::SharedBuffer(GBytes* bytes) > > I guess this can be a reference since it cannot be null. Nop, we never use references for C structs. > > Source/WebCore/platform/glib/SharedBufferGlib.cpp:37 > > +Ref<SharedBuffer> SharedBuffer::create(GBytes* bytes) > > Ditto.
Carlos Garcia Campos
Comment 4 2018-04-03 08:09:21 PDT
Radar WebKit Bug Importer
Comment 5 2018-04-03 08:10:22 PDT
Sergio Villar Senin
Comment 6 2018-04-04 00:31:38 PDT
(In reply to Carlos Garcia Campos from comment #3) > (In reply to Sergio Villar Senin from comment #2) > > Comment on attachment 337068 [details] > > Patch > > > > View in context: > > https://bugs.webkit.org/attachment.cgi?id=337068&action=review > > > > > Source/WebCore/platform/glib/SharedBufferGlib.cpp:30 > > > +SharedBuffer::SharedBuffer(GBytes* bytes) > > > > I guess this can be a reference since it cannot be null. > > Nop, we never use references for C structs. :) next time I'll check the actual type
Note You need to log in before you can comment on or make changes to this bug.