Bug 141273 - Avoid copying std::functions across threads in NetworkCacheStorage
Summary: Avoid copying std::functions across threads in NetworkCacheStorage
Alias: None
Product: WebKit
Classification: Unclassified
Component: Page Loading (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
Depends on:
Reported: 2015-02-04 16:19 PST by Antti Koivisto
Modified: 2015-02-05 06:32 PST (History)
2 users (show)

See Also:

patch (16.57 KB, patch)
2015-02-04 16:38 PST, Antti Koivisto
no flags Details | Formatted Diff | Diff
rebased (16.57 KB, patch)
2015-02-04 16:45 PST, Antti Koivisto
kling: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Antti Koivisto 2015-02-04 16:19:51 PST
The current behavior is bug-prone.
Comment 1 Antti Koivisto 2015-02-04 16:38:00 PST
Created attachment 246066 [details]
Comment 2 Antti Koivisto 2015-02-04 16:45:33 PST
Created attachment 246067 [details]
Comment 3 WebKit Commit Bot 2015-02-04 16:48:01 PST
Attachment 246067 [details] did not pass style-queue:

ERROR: Source/WebKit2/NetworkProcess/cache/NetworkCacheStorage.h:167:  Extra space before ( in function call  [whitespace/parens] [4]
ERROR: Source/WebKit2/NetworkProcess/cache/NetworkCacheStorage.h:174:  Extra space before ( in function call  [whitespace/parens] [4]
ERROR: Source/WebKit2/NetworkProcess/cache/NetworkCacheStorageCocoa.mm:410:  Extra space before ( in function call  [whitespace/parens] [4]
Total errors found: 3 in 4 files

If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 4 Andreas Kling 2015-02-04 16:49:12 PST
Comment on attachment 246067 [details]

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


> Source/WebKit2/NetworkProcess/cache/NetworkCacheStorageCocoa.mm:359
> +    auto& retrieve = *retrieveOperation;

Whenever I see code like this it makes me wonder if we should have a never-null unique_ptr.
Comment 5 Antti Koivisto 2015-02-05 06:32:10 PST