diff options
author | maruel@chromium.org <maruel@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-03-05 12:46:38 +0000 |
---|---|---|
committer | maruel@chromium.org <maruel@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-03-05 12:46:38 +0000 |
commit | f0a51fb571f46531025fa09240bbc3e1af925e84 (patch) | |
tree | 558b4f0e737fda4b9ab60f252c9c23b8a4ca523e /webkit/glue/multipart_response_delegate.cc | |
parent | 6390be368205705f49ead3cec40396519f13b889 (diff) | |
download | chromium_src-f0a51fb571f46531025fa09240bbc3e1af925e84.zip chromium_src-f0a51fb571f46531025fa09240bbc3e1af925e84.tar.gz chromium_src-f0a51fb571f46531025fa09240bbc3e1af925e84.tar.bz2 |
Fixes CRLF and trailing white spaces.
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10982 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/glue/multipart_response_delegate.cc')
-rw-r--r-- | webkit/glue/multipart_response_delegate.cc | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/webkit/glue/multipart_response_delegate.cc b/webkit/glue/multipart_response_delegate.cc index 58e8152..9e8e67d 100644 --- a/webkit/glue/multipart_response_delegate.cc +++ b/webkit/glue/multipart_response_delegate.cc @@ -42,7 +42,7 @@ MultipartResponseDelegate::MultipartResponseDelegate( } void MultipartResponseDelegate::OnReceivedData(const char* data, int data_len) { - // stop_sending_ means that we've already received the final boundary token. + // stop_sending_ means that we've already received the final boundary token. // The server should stop sending us data at this point, but if it does, we // just throw it away. if (stop_sending_) @@ -63,7 +63,7 @@ void MultipartResponseDelegate::OnReceivedData(const char* data, int data_len) { int pos = PushOverLine(data_, 0); if (pos) data_ = data_.substr(pos); - + if (data_.length() < boundary_.length() + 2) { // We don't have enough data yet to make a boundary token. Just wait // until the next chunk of data arrives. @@ -216,7 +216,7 @@ bool MultipartResponseDelegate::ParseHeaders() { } // Send the response! client_->didReceiveResponse(job_, response); - + return true; } @@ -256,11 +256,11 @@ bool MultipartResponseDelegate::ReadMultipartBoundary( content_type_as_string.find(';', boundary_start_offset); if (boundary_end_offset == std::string::npos) - boundary_end_offset = content_type_as_string.length(); + boundary_end_offset = content_type_as_string.length(); size_t boundary_length = boundary_end_offset - boundary_start_offset; - *multipart_boundary = + *multipart_boundary = content_type_as_string.substr(boundary_start_offset, boundary_length); // The byte range response can have quoted boundary strings. This is legal // as per MIME specifications. Individual data fragements however don't @@ -274,7 +274,7 @@ bool MultipartResponseDelegate::ReadContentRanges( int* content_range_lower_bound, int* content_range_upper_bound) { - std::string content_range = + std::string content_range = webkit_glue::StringToStdString( response.httpHeaderField("Content-Range")); @@ -293,7 +293,7 @@ bool MultipartResponseDelegate::ReadContentRanges( return false; } - size_t byte_range_lower_bound_characters = + size_t byte_range_lower_bound_characters = byte_range_lower_bound_end_offset - byte_range_lower_bound_start_offset; std::string byte_range_lower_bound = content_range.substr(byte_range_lower_bound_start_offset, |