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

Unified Diff: components/invalidation/impl/invalidator_storage.cc

Issue 2051663003: base::ListValue::Append cleanup: pass unique_ptr instead of the released pointer. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 6 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: components/invalidation/impl/invalidator_storage.cc
diff --git a/components/invalidation/impl/invalidator_storage.cc b/components/invalidation/impl/invalidator_storage.cc
index d40767d7333156a364479e360b3601a9ddce72a6..6da63dc6abedf4862150525098576f4fc1810737 100644
--- a/components/invalidation/impl/invalidator_storage.cc
+++ b/components/invalidation/impl/invalidator_storage.cc
@@ -44,7 +44,7 @@ std::unique_ptr<base::ListValue> UnackedInvalidationStorageMapToValue(
std::unique_ptr<base::ListValue> value(new base::ListValue);
for (syncer::UnackedInvalidationsMap::const_iterator it = map.begin();
it != map.end(); ++it) {
- value->Append(it->second.ToValue().release());
+ value->Append(it->second.ToValue());
}
return value;
}

Powered by Google App Engine
This is Rietveld 408576698