Bug 213409 - Remove unnecessary Timer from NetworkDataTask
Summary: Remove unnecessary Timer from NetworkDataTask
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Alex Christensen
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2020-06-19 15:06 PDT by Alex Christensen
Modified: 2020-06-23 13:58 PDT (History)
3 users (show)

See Also:


Attachments
Patch (6.89 KB, patch)
2020-06-19 15:09 PDT, Alex Christensen
no flags Details | Formatted Diff | Diff
Patch (8.66 KB, patch)
2020-06-23 11:03 PDT, Alex Christensen
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alex Christensen 2020-06-19 15:06:49 PDT
Remove unnecessary Timer from NetworkDataTask
Comment 1 Alex Christensen 2020-06-19 15:09:52 PDT
Created attachment 402332 [details]
Patch
Comment 2 youenn fablet 2020-06-23 06:27:30 PDT
Comment on attachment 402332 [details]
Patch

Please make sure to fix GTK/WPE/WIN
Comment 3 Alex Christensen 2020-06-23 11:03:50 PDT
Created attachment 402570 [details]
Patch
Comment 4 EWS 2020-06-23 11:41:13 PDT
Committed r263407: <https://trac.webkit.org/changeset/263407>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 402570 [details].
Comment 5 Radar WebKit Bug Importer 2020-06-23 11:42:16 PDT
<rdar://problem/64654646>
Comment 6 Darin Adler 2020-06-23 12:21:42 PDT
Comment on attachment 402570 [details]
Patch

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

> Source/WebKit/NetworkProcess/NetworkDataTask.cpp:100
> +        if (!weakThis || !m_client)
> +            return;

Is this a safe idiom? Do we have a guarantee that we are not racing with a deref of NetworkDataTask on another thread?
Comment 7 Alex Christensen 2020-06-23 13:58:00 PDT
Comment on attachment 402570 [details]
Patch

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

>> Source/WebKit/NetworkProcess/NetworkDataTask.cpp:100
>> +            return;
> 
> Is this a safe idiom? Do we have a guarantee that we are not racing with a deref of NetworkDataTask on another thread?

NetworkDataTask is always destroyed on the main thread because it uses WTF::DestructionThread::Main