Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fetch API: Don't DCHECK on a 302 response with a Location header with empty value. #9453

Merged
merged 1 commit into from Feb 14, 2018

Conversation

Projects
None yet
3 participants
@chromium-wpt-export-bot
Copy link
Collaborator

chromium-wpt-export-bot commented Feb 9, 2018

Blink was failing a DCHECK when it expected a redirect to be taken because
the request mode was 'follow' and the response had a redirect status code
and Location header. However, Chrome's //net considers a Location header
with an empty value to be the same as no Location header at all. See the
comments on bug 810288 about net::HttpResponseHeaders::IsRedirect().

WPT tests are added. The spec is unclear (whatwg/url#373)
but seems to either say to fail with network error or enter a loop of self-redirects
that will eventually hit the redirect limit and fail with network error.
Chrome currently fails this test because it treats the Location as
as non-existent, i.e., not a redirect response.

Bug: 810288,707185
Change-Id: Iaca93976aaa697380b1542ab45d63c318f5050b0
Reviewed-on: https://chromium-review.googlesource.com/910753
Reviewed-by: Yutaka Hirano yhirano@chromium.org
Reviewed-by: Tsuyoshi Horo horo@chromium.org
Commit-Queue: Matt Falkenhagen falken@chromium.org
Cr-Commit-Position: refs/heads/master@{#536644}

@wpt-pr-bot
Copy link
Collaborator

wpt-pr-bot left a comment

Already reviewed downstream.

@w3c-bots

This comment has been minimized.

Copy link

w3c-bots commented Feb 9, 2018

Build PASSED

Started: 2018-02-14 04:52:17
Finished: 2018-02-14 05:01:21

Failing Jobs

  • chrome:dev
  • safari:11.0
  • MicrosoftEdge:16.16299

View more information about this build on:

@chromium-wpt-export-bot chromium-wpt-export-bot force-pushed the chromium-export-cl-910753 branch 3 times, most recently from c31d213 to d140156 Feb 9, 2018

Fetch API: Don't DCHECK on a 302 response with a Location header with…
… empty value.

Blink was failing a DCHECK when it expected a redirect to be taken because
the request mode was 'follow' and the response had a redirect status code
and Location header. However, Chrome's //net considers a Location header
with an empty value to be the same as no Location header at all. See the
comments on bug 810288 about net::HttpResponseHeaders::IsRedirect().

WPT tests are added. The spec is unclear (whatwg/url#373)
but seems to either say to fail with network error or enter a loop of self-redirects
that will eventually hit the redirect limit and fail with network error.
Chrome currently fails this test because it treats the Location as
as non-existent, i.e., not a redirect response.

Bug: 810288,707185
Change-Id: Iaca93976aaa697380b1542ab45d63c318f5050b0
Reviewed-on: https://chromium-review.googlesource.com/910753
Reviewed-by: Yutaka Hirano <yhirano@chromium.org>
Reviewed-by: Tsuyoshi Horo <horo@chromium.org>
Commit-Queue: Matt Falkenhagen <falken@chromium.org>
Cr-Commit-Position: refs/heads/master@{#536644}

@chromium-wpt-export-bot chromium-wpt-export-bot force-pushed the chromium-export-cl-910753 branch from d140156 to d9f70eb Feb 14, 2018

@chromium-wpt-export-bot chromium-wpt-export-bot merged commit e757885 into master Feb 14, 2018

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details

@chromium-wpt-export-bot chromium-wpt-export-bot deleted the chromium-export-cl-910753 branch Feb 14, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.