Chromium Code Reviews| Index: net/spdy/spdy_stream.cc |
| diff --git a/net/spdy/spdy_stream.cc b/net/spdy/spdy_stream.cc |
| index 3dc00e9744f3c8902f6bda56242fee6b2d40c333..5aee9c30d6d910fd45c0c3e0cd0974b13e5bb858 100644 |
| --- a/net/spdy/spdy_stream.cc |
| +++ b/net/spdy/spdy_stream.cc |
| @@ -752,7 +752,8 @@ int SpdyStream::DoLoop(int result) { |
| break; |
| case STATE_SEND_BODY: |
| CHECK_EQ(result, OK); |
| - result = DoSendBody(); |
| + DoSendBody(); |
| + result = ERR_IO_PENDING; |
|
Ryan Hamilton
2013/05/22 03:17:30
Yeah, this looks weird to me. I think it fits our
akalin
2013/05/22 08:40:05
Done.
|
| break; |
| case STATE_SEND_BODY_COMPLETE: |
| result = DoSendBodyComplete(result); |
| @@ -902,7 +903,7 @@ int SpdyStream::DoSendHeadersComplete() { |
| // DoSendBody is called to send the optional body for the request. This call |
| // will also be called as each write of a chunk of the body completes. |
| -int SpdyStream::DoSendBody() { |
| +void SpdyStream::DoSendBody() { |
| // If we're already in the STATE_SEND_BODY state, then we've already |
| // sent a portion of the body. In that case, we need to first consume |
| // the bytes written in the body stream. Note that the bytes written is |
| @@ -910,9 +911,7 @@ int SpdyStream::DoSendBody() { |
| // data portion, of course. |
| io_state_ = STATE_SEND_BODY_COMPLETE; |
| CHECK(delegate_); |
| - int status = delegate_->OnSendBody(); |
| - CHECK(status == OK || status == ERR_IO_PENDING); |
| - return status; |
| + delegate_->OnSendBody(); |
| } |
| int SpdyStream::DoSendBodyComplete(int result) { |