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

Issue 268423002: Fix WebURLLoaderImpl::Context leak if a pending request is canceled. (Closed)

Created:
6 years, 7 months ago by kcwu
Modified:
6 years, 7 months ago
Reviewers:
kcwu1, jam, mmenke
CC:
chromium-reviews, darin-cc_chromium.org, Pawel Osciak
Visibility:
Public.

Description

Fix WebURLLoaderImpl::Context leak if a pending request is canceled. Now, ResourceDispatcher::CancelPendingRequest will send ResourceHostMsg_CancelRequest and trigger OnRequestComplete. However, the request is pending and thus OnRequestComplete will be queued. There are at least two problems if OnRequestComplete is not called: 1. WebURLLoaderImpl::Context will never be released. 2. request_info->buffer leaks. The buffer holds shared memory handle (file descriptor). fd leaking may lead to HW video decode failure on ChromeOS (detail in chrome-os-partner:27911#63) This issue is similar to issue 328092. BUG=chrome-os-partner:27911, chromium:369221, chromium:369128 R=jam@chromium.org, mmenke@chromium.org Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=269361

Patch Set 1 #

Patch Set 2 : #

Patch Set 3 : old CL #

Patch Set 4 : new CL #

Total comments: 4

Patch Set 5 : rephrase the comment #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+55 lines, -0 lines) Patch
M content/child/resource_dispatcher.h View 1 chunk +1 line, -0 lines 0 comments Download
M content/child/resource_dispatcher.cc View 1 2 3 4 4 chunks +54 lines, -0 lines 1 comment Download

Messages

Total messages: 12 (0 generated)
kcwu
The only difference to previous changeset is in ResourceDispatcher::CancelPendingRequest.
6 years, 7 months ago (2014-05-07 08:02:14 UTC) #1
jam
On 2014/05/07 08:02:14, kcwu wrote: > The only difference to previous changeset is in > ...
6 years, 7 months ago (2014-05-07 15:44:57 UTC) #2
kcwu1
On 2014/05/07 15:44:57, jam wrote: > On 2014/05/07 08:02:14, kcwu wrote: > > The only ...
6 years, 7 months ago (2014-05-08 02:37:50 UTC) #3
jam
https://codereview.chromium.org/268423002/diff/60001/content/child/resource_dispatcher.cc File content/child/resource_dispatcher.cc (right): https://codereview.chromium.org/268423002/diff/60001/content/child/resource_dispatcher.cc#newcode632 content/child/resource_dispatcher.cc:632: DispatchMessage(error_message); i don't understand this change. why are you ...
6 years, 7 months ago (2014-05-08 16:22:13 UTC) #4
kcwu1
https://codereview.chromium.org/268423002/diff/60001/content/child/resource_dispatcher.cc File content/child/resource_dispatcher.cc (right): https://codereview.chromium.org/268423002/diff/60001/content/child/resource_dispatcher.cc#newcode632 content/child/resource_dispatcher.cc:632: DispatchMessage(error_message); On 2014/05/08 16:22:13, jam wrote: > i don't ...
6 years, 7 months ago (2014-05-08 17:00:48 UTC) #5
jam
lgtm https://codereview.chromium.org/268423002/diff/60001/content/child/resource_dispatcher.cc File content/child/resource_dispatcher.cc (right): https://codereview.chromium.org/268423002/diff/60001/content/child/resource_dispatcher.cc#newcode632 content/child/resource_dispatcher.cc:632: DispatchMessage(error_message); On 2014/05/08 17:00:49, kcwu1 wrote: > On ...
6 years, 7 months ago (2014-05-08 17:03:52 UTC) #6
kcwu1
https://codereview.chromium.org/268423002/diff/60001/content/child/resource_dispatcher.cc File content/child/resource_dispatcher.cc (right): https://codereview.chromium.org/268423002/diff/60001/content/child/resource_dispatcher.cc#newcode632 content/child/resource_dispatcher.cc:632: DispatchMessage(error_message); On 2014/05/08 17:03:52, jam wrote: > On 2014/05/08 ...
6 years, 7 months ago (2014-05-08 17:14:53 UTC) #7
kcwu1
The CQ bit was checked by kcwu@google.com
6 years, 7 months ago (2014-05-08 17:25:27 UTC) #8
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/kcwu@chromium.org/268423002/80001
6 years, 7 months ago (2014-05-08 17:28:43 UTC) #9
mmenke
LGTM (Largely deferring to jam on this) https://codereview.chromium.org/268423002/diff/80001/content/child/resource_dispatcher.cc File content/child/resource_dispatcher.cc (right): https://codereview.chromium.org/268423002/diff/80001/content/child/resource_dispatcher.cc#newcode614 content/child/resource_dispatcher.cc:614: IPC::Message* message ...
6 years, 7 months ago (2014-05-08 17:53:59 UTC) #10
commit-bot: I haz the power
FYI, CQ is re-trying this CL (attempt #1). Please consider checking whether the failures are ...
6 years, 7 months ago (2014-05-08 22:22:08 UTC) #11
commit-bot: I haz the power
6 years, 7 months ago (2014-05-09 17:30:16 UTC) #12
Message was sent while issue was closed.
Change committed as 269361

Powered by Google App Engine
This is Rietveld 408576698