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

Unified Diff: net/disk_cache/simple/simple_entry_impl.cc

Issue 14362009: Receive app notifications in SimpleCache, so we save our index file (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: sync Created 7 years, 8 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
Index: net/disk_cache/simple/simple_entry_impl.cc
diff --git a/net/disk_cache/simple/simple_entry_impl.cc b/net/disk_cache/simple/simple_entry_impl.cc
index 78434496cc8802cfc55d0049d30d02d7424f06b2..fcb179150f9aba3159d6d38c8369b9a080d23561 100644
--- a/net/disk_cache/simple/simple_entry_impl.cc
+++ b/net/disk_cache/simple/simple_entry_impl.cc
@@ -63,6 +63,9 @@ int SimpleEntryImpl::CreateEntry(SimpleIndex* index,
const std::string& key,
Entry** entry,
const CompletionCallback& callback) {
+ // See comment on OpenEntry regarding inserting the entry in the index.
gavinp 2013/04/19 15:58:55 This is from another CL, it should be removed here
felipeg 2013/04/19 17:10:15 Done.
+ if (index)
+ index->Insert(key);
scoped_refptr<SimpleEntryImpl> new_entry =
new SimpleEntryImpl(index, path, key);
SynchronousCreationCallback sync_creation_callback =
@@ -334,8 +337,6 @@ void SimpleEntryImpl::CreationOperationComplete(
AddRef(); // Balanced in CloseInternal().
synchronous_entry_ = sync_entry;
SetSynchronousData();
- if (index_)
gavinp 2013/04/19 15:58:55 Same here?
felipeg 2013/04/19 17:10:15 Done.
- index_->Insert(key_);
*out_entry = this;
completion_callback.Run(net::OK);
}

Powered by Google App Engine
This is Rietveld 408576698