New issue
Advanced search Search tips

Issue 688922 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Feb 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 2
Type: Bug



Sign in to add a comment

Response('hello').body is an empty stream

Project Member Reported by yhirano@chromium.org, Feb 6 2017

Issue description

new Response('hello').body.getReader().read().then(({v, done}) => console.log(done))

should print false, but actually prints true.

 
Project Member

Comment 1 by bugdroid1@chromium.org, Feb 13 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/28ff32abc83ae8939f56702151b3d982859d56b5

commit 28ff32abc83ae8939f56702151b3d982859d56b5
Author: yhirano <yhirano@chromium.org>
Date: Mon Feb 13 14:09:23 2017

BodyStreamBuffer should take care the case where endRead returns Done

BytesConsumer::endRead may return Done, which means that in the function it
finds there is no more data.

BodyStreamBuffer::processData incorrectly dropped the data in such a case. This
CL fixes that.

BUG= 688922 
R=hiroshige@chromium.org

Review-Url: https://codereview.chromium.org/2671213003
Cr-Commit-Position: refs/heads/master@{#449947}

[modify] https://crrev.com/28ff32abc83ae8939f56702151b3d982859d56b5/third_party/WebKit/LayoutTests/http/tests/fetch/script-tests/response.js
[modify] https://crrev.com/28ff32abc83ae8939f56702151b3d982859d56b5/third_party/WebKit/Source/modules/fetch/BodyStreamBuffer.cpp

Labels: M-58
ok to mark as fixed?
Status: Fixed (was: Assigned)
Yes!

Sign in to add a comment