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

Issue 1454963003: ServiceWorker: Ensure that ServiceWorkerDispatcher always adopts passed handle references (1) (Closed)

Created:
5 years, 1 month ago by nhiroki
Modified:
5 years, 1 month ago
Reviewers:
falken
CC:
chromium-reviews, michaeln, jsbell+serviceworker_chromium.org, tzik, serviceworker-reviews, jam, kinuko+serviceworker, nhiroki, darin-cc_chromium.org, horo+watch_chromium.org, kinuko+watch, blink-worker-reviews_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

ServiceWorker: Ensure that ServiceWorkerDispatcher always adopts passed handle references (1) Some message handlers on ServiceWorkerDispatcher receive registration/worker handle references sent from the browser process. Those should surely be adopted by the dispatcher but not in some early-return cases. This means that handles in the browser process are leaked until renderer shutdown. This CL ensures that the dispatcher always adopts passed handle references at the beginning of message handlers related to registration association. The rest of the handlers will be treated in the subsequent CL. BUG=557655 Committed: https://crrev.com/4524454748a8676fdd6f1beae30810e4b0c13cac Cr-Commit-Position: refs/heads/master@{#360762}

Patch Set 1 : #

Total comments: 8

Patch Set 2 : rebase #

Patch Set 3 : address comments #

Unified diffs Side-by-side diffs Delta from patch set Stats (+166 lines, -25 lines) Patch
M content/child/service_worker/service_worker_dispatcher.h View 3 chunks +8 lines, -4 lines 0 comments Download
M content/child/service_worker/service_worker_dispatcher.cc View 3 chunks +35 lines, -7 lines 0 comments Download
M content/child/service_worker/service_worker_dispatcher_unittest.cc View 1 2 3 chunks +112 lines, -1 line 0 comments Download
M content/child/service_worker/service_worker_provider_context.h View 1 chunk +5 lines, -2 lines 0 comments Download
M content/child/service_worker/service_worker_provider_context.cc View 1 1 chunk +6 lines, -11 lines 0 comments Download

Messages

Total messages: 21 (14 generated)
nhiroki
PTAL, thanks!
5 years, 1 month ago (2015-11-19 10:04:19 UTC) #13
falken
Nice fix! https://codereview.chromium.org/1454963003/diff/80001/content/child/service_worker/service_worker_dispatcher_unittest.cc File content/child/service_worker/service_worker_dispatcher_unittest.cc (right): https://codereview.chromium.org/1454963003/diff/80001/content/child/service_worker/service_worker_dispatcher_unittest.cc#newcode174 content/child/service_worker/service_worker_dispatcher_unittest.cc:174: // The passed references should be adoped ...
5 years, 1 month ago (2015-11-20 03:35:54 UTC) #14
nhiroki
Thank you! Updated. https://codereview.chromium.org/1454963003/diff/80001/content/child/service_worker/service_worker_dispatcher_unittest.cc File content/child/service_worker/service_worker_dispatcher_unittest.cc (right): https://codereview.chromium.org/1454963003/diff/80001/content/child/service_worker/service_worker_dispatcher_unittest.cc#newcode174 content/child/service_worker/service_worker_dispatcher_unittest.cc:174: // The passed references should be ...
5 years, 1 month ago (2015-11-20 05:14:59 UTC) #16
falken
lgtm https://codereview.chromium.org/1454963003/diff/80001/content/child/service_worker/service_worker_dispatcher_unittest.cc File content/child/service_worker/service_worker_dispatcher_unittest.cc (right): https://codereview.chromium.org/1454963003/diff/80001/content/child/service_worker/service_worker_dispatcher_unittest.cc#newcode205 content/child/service_worker/service_worker_dispatcher_unittest.cc:205: info, attrs); On 2015/11/20 05:14:59, nhiroki wrote: > ...
5 years, 1 month ago (2015-11-20 05:26:25 UTC) #17
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1454963003/140001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1454963003/140001
5 years, 1 month ago (2015-11-20 05:30:58 UTC) #19
commit-bot: I haz the power
Committed patchset #3 (id:140001)
5 years, 1 month ago (2015-11-20 06:21:22 UTC) #20
commit-bot: I haz the power
5 years, 1 month ago (2015-11-20 06:22:12 UTC) #21
Message was sent while issue was closed.
Patchset 3 (id:??) landed as
https://crrev.com/4524454748a8676fdd6f1beae30810e4b0c13cac
Cr-Commit-Position: refs/heads/master@{#360762}

Powered by Google App Engine
This is Rietveld 408576698