Bug 187624 - PingLoad does not need to ref the NetworkConnectionToWebProcess
Summary: PingLoad does not need to ref the NetworkConnectionToWebProcess
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit2 (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Chris Dumez
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2018-07-12 15:49 PDT by Chris Dumez
Modified: 2018-07-12 16:47 PDT (History)
3 users (show)

See Also:


Attachments
Patch (3.62 KB, patch)
2018-07-12 15:53 PDT, Chris Dumez
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Chris Dumez 2018-07-12 15:49:57 PDT
PingLoad does not need to ref the NetworkConnectionToWebProcess and keep it alive longer than it needs to be.
Comment 1 Chris Dumez 2018-07-12 15:53:42 PDT
Created attachment 344893 [details]
Patch
Comment 2 youenn fablet 2018-07-12 15:59:20 PDT
Comment on attachment 344893 [details]
Patch

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

> Source/WebKit/NetworkProcess/NetworkConnectionToWebProcess.cpp:270
> +    auto completionHandler = [connection = m_connection.copyRef(), identifier = loadParameters.identifier] (const ResourceError& error, const ResourceResponse& response) {

Is it really safe?
LOL ;)
Comment 3 WebKit Commit Bot 2018-07-12 16:46:24 PDT
Comment on attachment 344893 [details]
Patch

Clearing flags on attachment: 344893

Committed r233787: <https://trac.webkit.org/changeset/233787>
Comment 4 WebKit Commit Bot 2018-07-12 16:46:26 PDT
All reviewed patches have been landed.  Closing bug.
Comment 5 Radar WebKit Bug Importer 2018-07-12 16:47:17 PDT
<rdar://problem/42143573>