diff options
author | jennb@chromium.org <jennb@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-12-22 18:22:23 +0000 |
---|---|---|
committer | jennb@chromium.org <jennb@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-12-22 18:22:23 +0000 |
commit | bdd42287e26666cb9230de0102045ccaa1e29207 (patch) | |
tree | fa5b66de3a049c67045e3cb5014b9d4d172efe17 /webkit/appcache/appcache_response.cc | |
parent | 1c5491c13d721e264432fe75e4030017b1ee10e8 (diff) | |
download | chromium_src-bdd42287e26666cb9230de0102045ccaa1e29207.zip chromium_src-bdd42287e26666cb9230de0102045ccaa1e29207.tar.gz chromium_src-bdd42287e26666cb9230de0102045ccaa1e29207.tar.bz2 |
Make appcache update conditionally include If-Modified-Since and If-None-Match headers when fetching a manifest.
TEST=new tests added
BUG=none
Review URL: http://codereview.chromium.org/500152
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@35153 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/appcache/appcache_response.cc')
-rw-r--r-- | webkit/appcache/appcache_response.cc | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/webkit/appcache/appcache_response.cc b/webkit/appcache/appcache_response.cc index 9ae5b29..09894a2 100644 --- a/webkit/appcache/appcache_response.cc +++ b/webkit/appcache/appcache_response.cc @@ -146,6 +146,11 @@ void AppCacheResponseReader::ReadInfo(HttpResponseInfoIOBuffer* info_buf, } int size = entry_->GetDataSize(kResponseInfoIndex); + if (size <= 0) { + ScheduleIOCompletionCallback(net::ERR_CACHE_MISS); + return; + } + info_buffer_ = info_buf; buffer_ = new net::IOBuffer(size); ReadRaw(kResponseInfoIndex, 0, buffer_.get(), size); |