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

Unified Diff: chrome/browser/sync/test/integration/extension_settings_helper.cc

Issue 24021002: Propagate more information about ValueStore errors to callers, notably an (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: add Pass*() Created 7 years, 3 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: chrome/browser/sync/test/integration/extension_settings_helper.cc
diff --git a/chrome/browser/sync/test/integration/extension_settings_helper.cc b/chrome/browser/sync/test/integration/extension_settings_helper.cc
index be57a4a9870523fdad57c1cc27cadbacb35eaa91..d2af3f3b23a92f6465511497d74cce4bb45a2b56 100644
--- a/chrome/browser/sync/test/integration/extension_settings_helper.cc
+++ b/chrome/browser/sync/test/integration/extension_settings_helper.cc
@@ -36,23 +36,22 @@ std::string ToJson(const Value& value) {
return json;
}
-void GetAllSettingsOnFileThread(
- scoped_ptr<DictionaryValue>* out,
- base::WaitableEvent* signal,
- ValueStore* storage) {
+void GetAllSettingsOnFileThread(DictionaryValue* out,
+ base::WaitableEvent* signal,
+ ValueStore* storage) {
CHECK(BrowserThread::CurrentlyOn(BrowserThread::FILE));
- out->swap(storage->Get()->settings());
+ out->Swap(&storage->Get()->settings());
signal->Signal();
}
scoped_ptr<DictionaryValue> GetAllSettings(
Profile* profile, const std::string& id) {
base::WaitableEvent signal(false, false);
- scoped_ptr<DictionaryValue> settings;
+ scoped_ptr<DictionaryValue> settings(new DictionaryValue());
profile->GetExtensionService()->settings_frontend()->RunWithStorage(
id,
extensions::settings_namespace::SYNC,
- base::Bind(&GetAllSettingsOnFileThread, &settings, &signal));
+ base::Bind(&GetAllSettingsOnFileThread, settings.get(), &signal));
signal.Wait();
return settings.Pass();
}
« no previous file with comments | « chrome/browser/extensions/api/storage/syncable_settings_storage.cc ('k') | chrome/browser/value_store/leveldb_value_store.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698