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

Issue 1800333003: Keep multipart images in m_nonBlockingLoaders after first part loaded (Closed)

Created:
4 years, 9 months ago by hiroshige
Modified:
4 years, 9 months ago
Reviewers:
Nate Chapin, yhirano
CC:
chromium-reviews, blink-reviews
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Keep multipart responses in m_nonBlockingLoaders after first part loaded For multipart responses, in the first ResourceLoader::didFinishLoadingOnePart(), (1) the ResourceLoader is moved from |m_loaders| to |m_nonBlockingLoaders| in ResourceFetcher::subresourceLoaderFinishedLoadingOnePart(), and (2) it is removed from |m_nonBlockingLoaders| in ResourceFetcher::willTerminateResourceLoader() called in didFinishLoading(). Therefore, if we call window.stop() just after multipart <img>'s onload event, we cannot stop loading of the multipart response because it is no longer in |m_loaders| nor |m_nonBlockingLoaders|. However, in the second didFinishLoadingOnePart(), (3) In subresourceLoaderFinishedLoadingOnePart(), the ResourceLoader is added again to |m_nonBlockingLoaders|, and (4) We don't call didFinishLoading()/willTerminateResourceLoader(). Therefore, we can stop loading of the image after that by window.stop(). This CL makes the ResourceLoader to be kept in |m_nonBlockingLoaders| after (1) and to be remove from |m_nonBlockingLoaders| when ResourceLoader::didFinishLoading() is called. This CL enables to stop loading of multipart responses at any time, and also enables https://codereview.chromium.org/1756953002/ to stop dispatching didFinishLoadingOnePart() for each part without affecting window.stop() behavior on multipart responses. BUG=570608 Committed: https://crrev.com/22822feaf74bffc00dbe6db27cd3e36c1c568e11 Cr-Commit-Position: refs/heads/master@{#381876}

Patch Set 1 #

Patch Set 2 : Add fix. #

Patch Set 3 : #

Patch Set 4 : #

Total comments: 2

Patch Set 5 : Reflect comments. #

Messages

Total messages: 34 (19 generated)
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1800333003/20001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1800333003/20001
4 years, 9 months ago (2016-03-15 22:46:35 UTC) #4
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1800333003/40001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1800333003/40001
4 years, 9 months ago (2016-03-15 22:57:57 UTC) #6
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1800333003/60001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1800333003/60001
4 years, 9 months ago (2016-03-15 23:24:53 UTC) #12
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
4 years, 9 months ago (2016-03-16 00:53:17 UTC) #15
hiroshige
PTAL.
4 years, 9 months ago (2016-03-16 01:01:54 UTC) #16
yhirano
lgtm, thanks. https://codereview.chromium.org/1800333003/diff/60001/third_party/WebKit/Source/core/fetch/ResourceLoader.cpp File third_party/WebKit/Source/core/fetch/ResourceLoader.cpp (right): https://codereview.chromium.org/1800333003/diff/60001/third_party/WebKit/Source/core/fetch/ResourceLoader.cpp#newcode132 third_party/WebKit/Source/core/fetch/ResourceLoader.cpp:132: if (!isFinishing()) { [optional] It might be ...
4 years, 9 months ago (2016-03-16 02:17:33 UTC) #17
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1800333003/80001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1800333003/80001
4 years, 9 months ago (2016-03-16 17:21:51 UTC) #19
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
4 years, 9 months ago (2016-03-16 20:54:42 UTC) #21
hiroshige
https://codereview.chromium.org/1800333003/diff/60001/third_party/WebKit/Source/core/fetch/ResourceLoader.cpp File third_party/WebKit/Source/core/fetch/ResourceLoader.cpp (right): https://codereview.chromium.org/1800333003/diff/60001/third_party/WebKit/Source/core/fetch/ResourceLoader.cpp#newcode132 third_party/WebKit/Source/core/fetch/ResourceLoader.cpp:132: if (!isFinishing()) { On 2016/03/16 02:17:33, yhirano wrote: > ...
4 years, 9 months ago (2016-03-16 21:18:43 UTC) #22
Nate Chapin
lgtm
4 years, 9 months ago (2016-03-17 22:32:15 UTC) #23
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1800333003/80001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1800333003/80001
4 years, 9 months ago (2016-03-17 22:53:39 UTC) #26
commit-bot: I haz the power
Try jobs failed on following builders: win_chromium_rel_ng on tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_rel_ng/builds/190780)
4 years, 9 months ago (2016-03-18 01:24:07 UTC) #28
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1800333003/80001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1800333003/80001
4 years, 9 months ago (2016-03-18 01:24:43 UTC) #30
commit-bot: I haz the power
Committed patchset #5 (id:80001)
4 years, 9 months ago (2016-03-18 02:52:06 UTC) #32
commit-bot: I haz the power
4 years, 9 months ago (2016-03-18 02:53:24 UTC) #34
Message was sent while issue was closed.
Patchset 5 (id:??) landed as
https://crrev.com/22822feaf74bffc00dbe6db27cd3e36c1c568e11
Cr-Commit-Position: refs/heads/master@{#381876}

Powered by Google App Engine
This is Rietveld 408576698