Summary: | [GTK][Unix] Implement missing WebKit::SharedMemory::create() function | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Adrian Perez <aperez> | ||||||
Component: | WebKitGTK | Assignee: | Adrian Perez <aperez> | ||||||
Status: | RESOLVED FIXED | ||||||||
Severity: | Normal | CC: | aestes, beidson, bugs-noreply, cgarcia, commit-queue, koivisto, mcatanzaro | ||||||
Priority: | P2 | ||||||||
Version: | Other | ||||||||
Hardware: | Unspecified | ||||||||
OS: | Unspecified | ||||||||
Bug Depends on: | |||||||||
Bug Blocks: | 154553 | ||||||||
Attachments: |
|
Description
Adrian Perez
2016-07-29 16:30:11 PDT
Created attachment 284916 [details]
Patch
Comment on attachment 284916 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=284916&action=review > Source/WebKit2/ChangeLog:3 > + Implement WebKit::SharedMemory::create() for the Unix platform. Please, use the actual bug title here. > Source/WebKit2/ChangeLog:14 > + (WebKit::accessModeMMap): Added helper function to convert a > + SharedMemory::Protection value into flags useable with mmap(). You are not adding it, but moving it, no? > Source/WebKit2/Platform/unix/SharedMemoryUnix.cpp:109 > +RefPtr<SharedMemory> SharedMemory::create(void* addr, size_t size, Protection protection) Do not use abbreviations, use either just data or address, but not addr > Source/WebKit2/Platform/unix/SharedMemoryUnix.cpp:153 > + return SharedMemory::create(0, size, SharedMemory::Protection::ReadWrite); Use nullptr instead of 0. Created attachment 284939 [details]
Patch
(In reply to comment #2) > Comment on attachment 284916 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=284916&action=review > > > Source/WebKit2/ChangeLog:3 > > + Implement WebKit::SharedMemory::create() for the Unix platform. > > Please, use the actual bug title here. Done. > > Source/WebKit2/ChangeLog:14 > > + (WebKit::accessModeMMap): Added helper function to convert a > > + SharedMemory::Protection value into flags useable with mmap(). > > You are not adding it, but moving it, no? The function did not exist before (It has a couple of lines picked from the old implementation of SharedMemory::allocate(), though). > > Source/WebKit2/Platform/unix/SharedMemoryUnix.cpp:109 > > +RefPtr<SharedMemory> SharedMemory::create(void* addr, size_t size, Protection protection) > > Do not use abbreviations, use either just data or address, but not addr > > > Source/WebKit2/Platform/unix/SharedMemoryUnix.cpp:153 > > + return SharedMemory::create(0, size, SharedMemory::Protection::ReadWrite); > > Use nullptr instead of 0. Fixed. Comment on attachment 284939 [details] Patch Clearing flags on attachment: 284939 Committed r203954: <http://trac.webkit.org/changeset/203954> All reviewed patches have been landed. Closing bug. |