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

Issue 2425173003: Deal with canceled requests when flushing deferred messages. (Closed)

Created:
4 years, 2 months ago by jb
Modified:
4 years, 1 month ago
Reviewers:
kinuko, jam
CC:
chromium-reviews, darin-cc_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Deal with canceled requests when flushing deferred messages. Flushing deferred messages might lead to a request being canceled (e.g. when an ImageResource loads a corrupt image). The code didn't fully take this into account which would cause crashes (and resource leaks if it would have survived). BUG= Committed: https://crrev.com/864cf45b30cce9d7cc15928a3e0b6be5422693c1 Cr-Commit-Position: refs/heads/master@{#427298}

Patch Set 1 #

Total comments: 4

Patch Set 2 : Added unittests for cancelling while flushing messages. #

Total comments: 2

Patch Set 3 : Made the is_deferred case a separate if again. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+131 lines, -20 lines) Patch
M content/child/resource_dispatcher.cc View 1 2 3 chunks +18 lines, -20 lines 0 comments Download
M content/child/resource_dispatcher_unittest.cc View 1 3 chunks +113 lines, -0 lines 0 comments Download

Messages

Total messages: 21 (9 generated)
jb
PTAL
4 years, 2 months ago (2016-10-18 11:59:46 UTC) #3
jam
This seems reasonable, but can you write a test? And is there no bug for ...
4 years, 2 months ago (2016-10-19 04:56:21 UTC) #5
jb
On 2016/10/19 04:56:21, jam wrote: > This seems reasonable, but can you write a test? ...
4 years, 2 months ago (2016-10-19 07:46:47 UTC) #7
kinuko
+1 to have some tests. How did you find the problem or do you have ...
4 years, 2 months ago (2016-10-19 13:35:53 UTC) #10
jb
https://codereview.chromium.org/2425173003/diff/1/content/child/resource_dispatcher.cc File content/child/resource_dispatcher.cc (right): https://codereview.chromium.org/2425173003/diff/1/content/child/resource_dispatcher.cc#newcode176 content/child/resource_dispatcher.cc:176: // Dispatches the messages only if the request is ...
4 years, 2 months ago (2016-10-20 13:06:50 UTC) #11
jb
On 2016/10/19 13:35:53, kinuko (slowish) wrote: > +1 to have some tests. How did you ...
4 years, 2 months ago (2016-10-20 13:24:35 UTC) #12
kinuko
The tests look great, thanks for adding them! LGTM % nit https://codereview.chromium.org/2425173003/diff/20001/content/child/resource_dispatcher.cc File content/child/resource_dispatcher.cc (right): ...
4 years, 2 months ago (2016-10-20 18:10:19 UTC) #13
jb
https://codereview.chromium.org/2425173003/diff/20001/content/child/resource_dispatcher.cc File content/child/resource_dispatcher.cc (right): https://codereview.chromium.org/2425173003/diff/20001/content/child/resource_dispatcher.cc#newcode179 content/child/resource_dispatcher.cc:179: } On 2016/10/20 18:10:18, kinuko (slowish) wrote: > nit: ...
4 years, 2 months ago (2016-10-21 07:28:48 UTC) #14
kinuko
On 2016/10/21 07:28:48, jb wrote: > https://codereview.chromium.org/2425173003/diff/20001/content/child/resource_dispatcher.cc > File content/child/resource_dispatcher.cc (right): > > https://codereview.chromium.org/2425173003/diff/20001/content/child/resource_dispatcher.cc#newcode179 > ...
4 years, 1 month ago (2016-10-24 14:12:06 UTC) #15
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2425173003/40001
4 years, 1 month ago (2016-10-25 06:50:15 UTC) #17
commit-bot: I haz the power
Committed patchset #3 (id:40001)
4 years, 1 month ago (2016-10-25 08:34:47 UTC) #19
commit-bot: I haz the power
4 years, 1 month ago (2016-10-25 08:37:02 UTC) #21
Message was sent while issue was closed.
Patchset 3 (id:??) landed as
https://crrev.com/864cf45b30cce9d7cc15928a3e0b6be5422693c1
Cr-Commit-Position: refs/heads/master@{#427298}

Powered by Google App Engine
This is Rietveld 408576698