|
|
Created:
6 years, 4 months ago by tyoshino (SeeGerritForStatus) Modified:
6 years, 3 months ago CC:
chromium-reviews, darin-cc_chromium.org, jam Base URL:
svn://svn.chromium.org/chrome/trunk/src Project:
chromium Visibility:
Public. |
Description[WebURLLoaderImpl] Don't respond to data URL request if downloadToFile is set
BUG=405841
Committed: https://crrev.com/30b387429c8f5c7485b82d12bb70cc6181231020
Cr-Commit-Position: refs/heads/master@{#293905}
Patch Set 1 #
Total comments: 2
Patch Set 2 : #
Total comments: 1
Patch Set 3 : Added the main change I wanted to make by this CL #
Total comments: 2
Patch Set 4 : Addressed #12 #
Total comments: 2
Patch Set 5 : Addressed #18 #Messages
Total messages: 24 (4 generated)
Do we have a test to cover this if we break this again? :)
On 2014/08/21 15:18:31, eseidel wrote: > Do we have a test to cover this if we break this again? :) Sorry. I forgot to enable and recheck the data URL layout tests https://codereview.chromium.org/492183002/. The tests cover this change.
ping as 1 w passed. The layout test (https://codereview.chromium.org/492183002/) will be checked in later.
I would lgtm if I could, but I don't have the power. I would try adding more content/ reviewers. I've been told they're a dying breed.
On 2014/08/28 15:14:53, eseidel wrote: > I would lgtm if I could, but I don't have the power. I would try adding more > content/ reviewers. I've been told they're a dying breed. +jam This is required to reland https://codereview.chromium.org/294193002.
tyoshino@chromium.org changed reviewers: + jam@chromium.org
+jam This is required to reland https://codereview.chromium.org/294193002.
lgtm
https://codereview.chromium.org/480413007/diff/20001/content/child/web_url_lo... File content/child/web_url_loader_impl.cc (right): https://codereview.chromium.org/480413007/diff/20001/content/child/web_url_lo... content/child/web_url_loader_impl.cc:662: return false; Hmm, it didn't compile. I don't remember if I forgot to compile. We need to create a GURL instance to call GURL::SchemeIs() Fixed
Sorry, Eric, John. This CL didn't include the main change but just refactoring of the CanHandleDataURL() method... I added it in the patch set 3. PTAL.
https://codereview.chromium.org/480413007/diff/40001/content/child/web_url_lo... File content/child/web_url_loader_impl.cc (right): https://codereview.chromium.org/480413007/diff/40001/content/child/web_url_lo... content/child/web_url_loader_impl.cc:315: if (IsHandlableDataURLRequest()) { I would have used the active voice "CanHandleDataURLRequest()" instead of passive "is handleable". I might also have written a unittest for your new function. But otherwise lgtm.
https://codereview.chromium.org/480413007/diff/40001/content/child/web_url_lo... File content/child/web_url_loader_impl.cc (right): https://codereview.chromium.org/480413007/diff/40001/content/child/web_url_lo... content/child/web_url_loader_impl.cc:315: if (IsHandlableDataURLRequest()) { On 2014/09/04 16:31:25, eseidel wrote: > I would have used the active voice "CanHandleDataURLRequest()" instead of > passive "is handleable". In the name, I also wanted to mean that we're checking whether request_ is data URL request or not. I.e. IsDataURLRequest && CanHandleByFastPath -> IsHandlableDataURLRequest. How about CanHandleRequestWithDataURLParser? > > I might also have written a unittest for your new function. The algorithm added is very simple. As darin suggested that I don't export and test GetInfoFromDataURL() in the last CL, I'd also like to skip adding tests for this. > > But otherwise lgtm.
sgtm. lgtm On Fri, Sep 5, 2014 at 7:05 AM, <tyoshino@chromium.org> wrote: > > https://codereview.chromium.org/480413007/diff/40001/content/child/web_url_lo... > File content/child/web_url_loader_impl.cc (right): > > https://codereview.chromium.org/480413007/diff/40001/content/child/web_url_lo... > content/child/web_url_loader_impl.cc:315: if > (IsHandlableDataURLRequest()) { > On 2014/09/04 16:31:25, eseidel wrote: >> >> I would have used the active voice "CanHandleDataURLRequest()" instead > > of >> >> passive "is handleable". > > > In the name, I also wanted to mean that we're checking whether request_ > is data URL request or not. I.e. IsDataURLRequest && CanHandleByFastPath > -> IsHandlableDataURLRequest. > > How about CanHandleRequestWithDataURLParser? > > >> I might also have written a unittest for your new function. > > > The algorithm added is very simple. As darin suggested that I don't > export and test GetInfoFromDataURL() in the last CL, I'd also like to > skip adding tests for this. > > > >> But otherwise lgtm. > > > https://codereview.chromium.org/480413007/ To unsubscribe from this group and stop receiving emails from it, send an email to chromium-reviews+unsubscribe@chromium.org.
lgtm
The CQ bit was checked by tyoshino@chromium.org
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/tyoshino@chromium.org/480413007/60001
https://codereview.chromium.org/480413007/diff/1/content/child/web_url_loader... File content/child/web_url_loader_impl.cc (right): https://codereview.chromium.org/480413007/diff/1/content/child/web_url_loader... content/child/web_url_loader_impl.cc:318: if (IsHandlableDataURLRequest()) { Hmm, "Handleable" is probably a better spelling than "Handlable", but it still reads fairly awkwardly. How about ShouldHandleDataURLRequest? https://codereview.chromium.org/480413007/diff/60001/content/child/web_url_lo... File content/child/web_url_loader_impl.cc (right): https://codereview.chromium.org/480413007/diff/60001/content/child/web_url_lo... content/child/web_url_loader_impl.cc:659: bool WebURLLoaderImpl::Context::CanHandleRequestWithDataURLParser() const { I don't mean to hold up this CL or anything, so forgive the nit-pick. This name suggests that elsewhere the DataURL is handled using something other than the DataURL parser. But, in fact it is still handled using the same DataURL parser in the browser process. Both here and there use the same parser. The difference is that we can sometimes use the parser locally without delegating to the ResourceLoaderBridge. Hence, something like CanHandleDataURLRequestLocally might be a more accurate name. Anyways, sorry to nit pick on names! But, there... I think that's a better name :)
The CQ bit was unchecked by tyoshino@chromium.org
https://codereview.chromium.org/480413007/diff/1/content/child/web_url_loader... File content/child/web_url_loader_impl.cc (right): https://codereview.chromium.org/480413007/diff/1/content/child/web_url_loader... content/child/web_url_loader_impl.cc:318: if (IsHandlableDataURLRequest()) { On 2014/09/09 05:59:11, darin wrote: > Hmm, "Handleable" is probably a better spelling than "Handlable", but it still > reads fairly awkwardly. How about ShouldHandleDataURLRequest? Thanks for suggestion. https://codereview.chromium.org/480413007/diff/60001/content/child/web_url_lo... File content/child/web_url_loader_impl.cc (right): https://codereview.chromium.org/480413007/diff/60001/content/child/web_url_lo... content/child/web_url_loader_impl.cc:659: bool WebURLLoaderImpl::Context::CanHandleRequestWithDataURLParser() const { On 2014/09/09 05:59:11, darin wrote: > I don't mean to hold up this CL or anything, so forgive the nit-pick. This name > suggests that elsewhere the DataURL is handled using something other than the > DataURL parser. But, in fact it is still handled using the same DataURL parser > in the browser process. Both here and there use the same parser. The difference > is that we can sometimes use the parser locally without delegating to the > ResourceLoaderBridge. > > Hence, something like CanHandleDataURLRequestLocally might be a more accurate > name. > > Anyways, sorry to nit pick on names! But, there... I think that's a better name > :) OK! Fixed
The CQ bit was checked by tyoshino@chromium.org
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/tyoshino@chromium.org/480413007/80001
Message was sent while issue was closed.
Committed patchset #5 (id:80001) as 91101840657c4367c196e4bf6730263fe86a2c12
Message was sent while issue was closed.
Patchset 5 (id:??) landed as https://crrev.com/30b387429c8f5c7485b82d12bb70cc6181231020 Cr-Commit-Position: refs/heads/master@{#293905} |