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

Unified Diff: net/http/http_cache_transaction.cc

Issue 545101: Http cache: If we issue a byte range request for x bytes... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 10 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 | « no previous file | net/http/http_cache_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/http/http_cache_transaction.cc
===================================================================
--- net/http/http_cache_transaction.cc (revision 36420)
+++ net/http/http_cache_transaction.cc (working copy)
@@ -1527,8 +1527,12 @@
if (result < 0)
return result;
- if (partial_.get())
- return DoPartialNetworkReadCompleted(result);
+ if (partial_.get()) {
+ // This may be the last request.
+ if (!(result == 0 && !truncated_ &&
+ (partial_->IsLastRange() || mode_ == WRITE)))
+ return DoPartialNetworkReadCompleted(result);
+ }
if (result == 0) // End of file.
DoneWritingToEntry(true);
« no previous file with comments | « no previous file | net/http/http_cache_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698