Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(200)

Issue 874003002: Oilpan: dispose ServiceWorker (and registration) objects earlier. (Closed)

Created:
5 years, 11 months ago by sof
Modified:
5 years, 11 months ago
Reviewers:
oilpan-reviews, haraken
CC:
blink-reviews, michaeln, jsbell+serviceworker_chromium.org, Mads Ager (chromium), tzik, serviceworker-reviews, nhiroki, falken, oilpan-reviews, kinuko+serviceworker, haraken, horo+watch_chromium.org, kouhei+heap_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/blink.git@master
Target Ref:
refs/heads/master
Project:
blink
Visibility:
Public.

Description

Oilpan: dispose ServiceWorker (and registration) objects earlier. It is unsafe to keep a ServiceWorker registered with the embedder once it has been determined to be unreachable by the garbage collector, but not yet finalized, as it cannot be assumed to be in a valid state beyond that point. Hence, we detach and unregister the object during a pre-finalization step. The same lifetime issue applies to ServiceWorkerRegistration, so extend the same treatment to it also. R=haraken BUG=451692 Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=188949

Patch Set 1 #

Total comments: 9

Patch Set 2 : tidying #

Unified diffs Side-by-side diffs Delta from patch set Stats (+52 lines, -0 lines) Patch
M Source/modules/serviceworkers/ServiceWorker.h View 1 2 chunks +5 lines, -0 lines 0 comments Download
M Source/modules/serviceworkers/ServiceWorker.cpp View 1 1 chunk +25 lines, -0 lines 0 comments Download
M Source/modules/serviceworkers/ServiceWorkerRegistration.h View 1 3 chunks +4 lines, -0 lines 0 comments Download
M Source/modules/serviceworkers/ServiceWorkerRegistration.cpp View 1 2 chunks +12 lines, -0 lines 0 comments Download
M Source/platform/heap/ThreadState.h View 1 1 chunk +6 lines, -0 lines 0 comments Download

Messages

Total messages: 11 (3 generated)
sof
Please take a look. Option #2 (https://code.google.com/p/chromium/issues/detail?id=451692#c1) seems the right way forward here, given the ...
5 years, 11 months ago (2015-01-24 19:26:43 UTC) #2
haraken
LGTM https://codereview.chromium.org/874003002/diff/1/Source/modules/serviceworkers/ServiceWorker.cpp File Source/modules/serviceworkers/ServiceWorker.cpp (right): https://codereview.chromium.org/874003002/diff/1/Source/modules/serviceworkers/ServiceWorker.cpp#newcode269 Source/modules/serviceworkers/ServiceWorker.cpp:269: { Can we add ASSERT(!m_outerWorker)? https://codereview.chromium.org/874003002/diff/1/Source/modules/serviceworkers/ServiceWorkerRegistration.cpp File Source/modules/serviceworkers/ServiceWorkerRegistration.cpp ...
5 years, 11 months ago (2015-01-26 01:39:42 UTC) #4
sof
https://codereview.chromium.org/874003002/diff/1/Source/modules/serviceworkers/ServiceWorkerRegistration.h File Source/modules/serviceworkers/ServiceWorkerRegistration.h (right): https://codereview.chromium.org/874003002/diff/1/Source/modules/serviceworkers/ServiceWorkerRegistration.h#newcode34 Source/modules/serviceworkers/ServiceWorkerRegistration.h:34: WILL_BE_USING_PRE_FINALIZER(ServiceWorkerRegistration, dispose); On 2015/01/26 01:39:42, haraken wrote: > > ...
5 years, 11 months ago (2015-01-26 06:21:41 UTC) #5
haraken
https://codereview.chromium.org/874003002/diff/1/Source/modules/serviceworkers/ServiceWorkerRegistration.h File Source/modules/serviceworkers/ServiceWorkerRegistration.h (right): https://codereview.chromium.org/874003002/diff/1/Source/modules/serviceworkers/ServiceWorkerRegistration.h#newcode34 Source/modules/serviceworkers/ServiceWorkerRegistration.h:34: WILL_BE_USING_PRE_FINALIZER(ServiceWorkerRegistration, dispose); On 2015/01/26 06:21:41, sof wrote: > On ...
5 years, 11 months ago (2015-01-26 06:29:03 UTC) #6
sof
https://codereview.chromium.org/874003002/diff/1/Source/modules/serviceworkers/ServiceWorker.cpp File Source/modules/serviceworkers/ServiceWorker.cpp (right): https://codereview.chromium.org/874003002/diff/1/Source/modules/serviceworkers/ServiceWorker.cpp#newcode269 Source/modules/serviceworkers/ServiceWorker.cpp:269: { On 2015/01/26 01:39:42, haraken wrote: > > Can ...
5 years, 11 months ago (2015-01-26 06:32:47 UTC) #7
sof
https://codereview.chromium.org/874003002/diff/1/Source/modules/serviceworkers/ServiceWorkerRegistration.cpp File Source/modules/serviceworkers/ServiceWorkerRegistration.cpp (right): https://codereview.chromium.org/874003002/diff/1/Source/modules/serviceworkers/ServiceWorkerRegistration.cpp#newcode183 Source/modules/serviceworkers/ServiceWorkerRegistration.cpp:183: m_outerRegistration.clear(); On 2015/01/26 01:39:42, haraken wrote: > > Can ...
5 years, 11 months ago (2015-01-26 10:06:57 UTC) #8
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/874003002/20001
5 years, 11 months ago (2015-01-26 10:07:44 UTC) #10
commit-bot: I haz the power
5 years, 11 months ago (2015-01-26 11:29:00 UTC) #11
Message was sent while issue was closed.
Committed patchset #2 (id:20001) as
https://src.chromium.org/viewvc/blink?view=rev&revision=188949

Powered by Google App Engine
This is Rietveld 408576698