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

Unified Diff: net/disk_cache/entry_impl.cc

Issue 256090: Disk cache: Add a method to cancel pending sparse operations.... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 2 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 | « net/disk_cache/entry_impl.h ('k') | net/disk_cache/entry_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/disk_cache/entry_impl.cc
===================================================================
--- net/disk_cache/entry_impl.cc (revision 28049)
+++ net/disk_cache/entry_impl.cc (working copy)
@@ -384,6 +384,20 @@
return sparse_->GetAvailableRange(offset, len, start);
}
+void EntryImpl::CancelSparseIO() {
+ if (!sparse_.get())
+ return;
+
+ sparse_->CancelIO();
+}
+
+int EntryImpl::ReadyForSparseIO(net::CompletionCallback* completion_callback) {
+ if (!sparse_.get())
+ return net::OK;
+
+ return sparse_->ReadyToUse(completion_callback);
+}
+
// ------------------------------------------------------------------------
uint32 EntryImpl::GetHash() {
« no previous file with comments | « net/disk_cache/entry_impl.h ('k') | net/disk_cache/entry_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698