RESOLVED FIXED 142392
Move dispatch_data use behind NetworkCache::Data abstraction
https://bugs.webkit.org/show_bug.cgi?id=142392
Summary Move dispatch_data use behind NetworkCache::Data abstraction
Antti Koivisto
Reported 2015-03-06 05:14:03 PST
Less platform dependent code
Attachments
patch (12.24 KB, patch)
2015-03-06 05:37 PST, Antti Koivisto
no flags
patch (12.67 KB, patch)
2015-03-06 06:15 PST, Antti Koivisto
andersca: review+
Antti Koivisto
Comment 1 2015-03-06 05:37:33 PST
WebKit Commit Bot
Comment 2 2015-03-06 05:40:08 PST
Attachment 248059 [details] did not pass style-queue: ERROR: Source/WebKit2/NetworkProcess/cache/NetworkCacheData.h:113: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit2/NetworkProcess/cache/NetworkCacheDataCocoa.mm:66: Extra space before ( in function call [whitespace/parens] [4] Total errors found: 2 in 5 files If any of these errors are false positives, please file a bug against check-webkit-style.
Antti Koivisto
Comment 3 2015-03-06 06:15:18 PST
WebKit Commit Bot
Comment 4 2015-03-06 06:17:48 PST
Attachment 248060 [details] did not pass style-queue: ERROR: Source/WebKit2/NetworkProcess/cache/NetworkCacheData.h:113: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit2/NetworkProcess/cache/NetworkCacheDataCocoa.mm:67: Extra space before ( in function call [whitespace/parens] [4] Total errors found: 2 in 5 files If any of these errors are false positives, please file a bug against check-webkit-style.
Anders Carlsson
Comment 5 2015-03-06 08:23:45 PST
Comment on attachment 248060 [details] patch View in context: https://bugs.webkit.org/attachment.cgi?id=248060&action=review > Source/WebKit2/NetworkProcess/cache/NetworkCacheData.h:113 > + void apply(std::function<bool (const uint8_t*, size_t)>&&) const; I think the function can be const& here. > Source/WebKit2/NetworkProcess/cache/NetworkCacheDataCocoa.mm:70 > + if (!m_size) > + return; It's a little weird that calling apply on an empty Data results in nothing happening. > Source/WebKit2/NetworkProcess/cache/NetworkCacheStorageCocoa.mm:264 > + Vector<uint8_t, 4096> filler(dataOffset - headerData.size(), 0); I'd use an std::array here instead.
Antti Koivisto
Comment 6 2015-03-06 09:31:59 PST
Note You need to log in before you can comment on or make changes to this bug.