diff options
author | rtenneti@chromium.org <rtenneti@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-07-12 01:00:40 +0000 |
---|---|---|
committer | rtenneti@chromium.org <rtenneti@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-07-12 01:00:40 +0000 |
commit | e37ce37a62b59a55d2c7f90cae0dc7c7dec6a038 (patch) | |
tree | f58e9e44aa649a129478c4ff12eaa0ee7afe9e4d /net/base/upload_data_stream.cc | |
parent | 91066fd43e011a34aea9140739c39c653425a823 (diff) | |
download | chromium_src-e37ce37a62b59a55d2c7f90cae0dc7c7dec6a038.zip chromium_src-e37ce37a62b59a55d2c7f90cae0dc7c7dec6a038.tar.gz chromium_src-e37ce37a62b59a55d2c7f90cae0dc7c7dec6a038.tar.bz2 |
SPDY - chunked upload - cleanup of spdy_http_stream to read the data
in SendBody instead of SendBodyComplete.
SpdyHttpStream inherits from ChunkCallback (SpdyStream doesn't inherit
from ChunkCallback). OnChunkAvailable is handled by SpdyHttpStream.
In unit tests, added new tests (similar to http_stream_parser_unittest
for chunked uploads), to delay sending of chunked data.
Also added sending of window_update during chunk uploads. Verified
that these tests fail with the old code and run ok with the new changes.
This change also fixed chunked uploads hanging (or stalling) for
speech recgonition.
Many many thanks to sleevi for suggesting the way to clean up
the SpdyHttpStream's SendBody and SendBodyComplete code.
R=rch@chromium.org, rsleevi@chromium.org
TEST=network unit tests
BUG=113107, 136044
Review URL: https://chromiumcodereview.appspot.com/10689034
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@146255 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/base/upload_data_stream.cc')
-rw-r--r-- | net/base/upload_data_stream.cc | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/net/base/upload_data_stream.cc b/net/base/upload_data_stream.cc index e86c1b3..9791a91 100644 --- a/net/base/upload_data_stream.cc +++ b/net/base/upload_data_stream.cc @@ -15,6 +15,12 @@ namespace net { bool UploadDataStream::merge_chunks_ = true; +// static +void UploadDataStream::ResetMergeChunks() { + // WARNING: merge_chunks_ must match the above initializer. + merge_chunks_ = true; +} + UploadDataStream::UploadDataStream(UploadData* upload_data) : upload_data_(upload_data), element_index_(0), |