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

Unified Diff: ios/chrome/browser/favicon/large_icon_cache.cc

Issue 1763273002: base: Remove OwningMRUCache in favor of scoped_ptrs in MRUCache (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase + fix Created 4 years, 9 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: ios/chrome/browser/favicon/large_icon_cache.cc
diff --git a/ios/chrome/browser/favicon/large_icon_cache.cc b/ios/chrome/browser/favicon/large_icon_cache.cc
index 2841a675db0653d7b1150e65b5652ca659c37c17..b05b79b9946889b7ec3193ca48db48b7a767dcea 100644
--- a/ios/chrome/browser/favicon/large_icon_cache.cc
+++ b/ios/chrome/browser/favicon/large_icon_cache.cc
@@ -28,9 +28,9 @@ LargeIconCache::~LargeIconCache() {}
void LargeIconCache::SetCachedResult(
const GURL& url,
const favicon_base::LargeIconResult& result) {
- LargeIconCacheEntry* entry = new LargeIconCacheEntry;
+ scoped_ptr<LargeIconCacheEntry> entry(new LargeIconCacheEntry);
entry->result = CloneLargeIconResult(result);
- cache_.Put(url, entry);
+ cache_.Put(url, std::move(entry));
}
scoped_ptr<favicon_base::LargeIconResult> LargeIconCache::GetCachedResult(

Powered by Google App Engine
This is Rietveld 408576698