Bug 238860

Summary: ServiceWorkerDownloadTask starts listening for IPC in constructor
Product: WebKit Reporter: Kimmo Kinnunen <kkinnunen>
Component: Service WorkersAssignee: Kimmo Kinnunen <kkinnunen>
Status: RESOLVED FIXED    
Severity: Normal CC: cdumez, webkit-bug-importer, youennf
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch none

Kimmo Kinnunen
Reported 2022-04-06 04:04:06 PDT
ServiceWorkerDownloadTask starts listening for IPC in constructor
Attachments
Patch (6.88 KB, patch)
2022-04-06 04:10 PDT, Kimmo Kinnunen
no flags
Patch (6.88 KB, patch)
2022-04-06 04:12 PDT, Kimmo Kinnunen
no flags
Kimmo Kinnunen
Comment 1 2022-04-06 04:10:07 PDT
Kimmo Kinnunen
Comment 2 2022-04-06 04:12:05 PDT
youenn fablet
Comment 3 2022-04-06 04:48:07 PDT
Comment on attachment 456804 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=456804&action=review > Source/WebKit/ChangeLog:10 > + virtual function table of the `this` object has not been constructed fully yet. This means I am not sure this is entirely exact, ServiceWorkerDownloadTask is the derived class. In any case, calling virtual methods in constructor is probably best be avoided.
Kimmo Kinnunen
Comment 4 2022-04-06 06:06:10 PDT
(In reply to youenn fablet from comment #3) > > Source/WebKit/ChangeLog:10 > > + virtual function table of the `this` object has not been constructed fully yet. This means > > I am not sure this is entirely exact, ServiceWorkerDownloadTask is the > derived class. > In any case, calling virtual methods in constructor is probably best be > avoided. This is exactly the case with the derived classes. vptr is not thread-safe -- it will be correct only after all constructors have returned.
EWS
Comment 5 2022-04-06 09:01:24 PDT
Committed r292471 (249322@main): <https://commits.webkit.org/249322@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 456804 [details].
Radar WebKit Bug Importer
Comment 6 2022-04-06 09:02:26 PDT
Note You need to log in before you can comment on or make changes to this bug.