[webkit-reviews] review granted: [Bug 197264] Make NetworkCache blobs safe for mmap instead of not using blobs : [Attachment 368213] Patch
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Thu Apr 25 00:38:06 PDT 2019
Antti Koivisto <koivisto at iki.fi> has granted Alex Christensen
<achristensen at apple.com>'s request for review:
Bug 197264: Make NetworkCache blobs safe for mmap instead of not using blobs
https://bugs.webkit.org/show_bug.cgi?id=197264
Attachment 368213: Patch
https://bugs.webkit.org/attachment.cgi?id=368213&action=review
--- Comment #3 from Antti Koivisto <koivisto at iki.fi> ---
Comment on attachment 368213
--> https://bugs.webkit.org/attachment.cgi?id=368213
Patch
View in context: https://bugs.webkit.org/attachment.cgi?id=368213&action=review
Looks fine except the part where it doesn't build.
> Source/WebKit/NetworkProcess/cache/NetworkCacheBlobStorage.cpp:97
> + makeSafeToUseMemoryMapForPath(blobPathString);
Can't you do this after the existence test? Or do you specifically want to
upgrade existing files?
> Source/WebKit/NetworkProcess/cache/NetworkCacheStorage.cpp:-281
> -static size_t estimateRecordsSize(unsigned recordCount, unsigned blobCount)
> -{
> - auto inlineBodyCount = recordCount - std::min(blobCount, recordCount);
> - auto headerSizes = recordCount * 4096;
> - auto inlineBodySizes = (maximumInlineBodySize / 2) * inlineBodyCount;
> - return headerSizes + inlineBodySizes;
> -}
You can't delete this function!
> Source/WebKit/NetworkProcess/cache/NetworkCacheStorage.cpp:315
>
...because you call it here.
More information about the webkit-reviews
mailing list