Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(8393)

Unified Diff: chrome_frame/urlmon_upload_data_stream.cc

Issue 6357017: Add support for chunked encoding in ChromeFrame for POST requests. This fixes... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome_frame/test/net/fake_external_tab.cc ('k') | chrome_frame/urlmon_url_request.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome_frame/urlmon_upload_data_stream.cc
===================================================================
--- chrome_frame/urlmon_upload_data_stream.cc (revision 72649)
+++ chrome_frame/urlmon_upload_data_stream.cc (working copy)
@@ -20,7 +20,7 @@
}
// Have we already read past the end of the stream?
- if (request_body_stream_->position() >= request_body_stream_->size()) {
+ if (request_body_stream_->eof()) {
if (read) {
*read = 0;
}
@@ -28,8 +28,7 @@
}
uint64 total_bytes_to_copy = std::min(static_cast<uint64>(cb),
- request_body_stream_->size() - request_body_stream_->position());
- uint64 initial_position = request_body_stream_->position();
+ static_cast<uint64>(request_body_stream_->buf_len()));
uint64 bytes_copied = 0;
@@ -55,8 +54,6 @@
}
DCHECK(bytes_copied == total_bytes_to_copy);
- DCHECK(request_body_stream_->position() ==
- initial_position + total_bytes_to_copy);
if (read) {
*read = static_cast<ULONG>(total_bytes_to_copy);
« no previous file with comments | « chrome_frame/test/net/fake_external_tab.cc ('k') | chrome_frame/urlmon_url_request.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698