chore: use std::make_unique/base::MakeRefCounted when possible (#29510)
This commit is contained in:
parent
a4decffe9a
commit
79cb5144ae
38 changed files with 106 additions and 101 deletions
|
@ -112,8 +112,9 @@ void BrowserProcessImpl::PostEarlyInitialization() {
|
|||
user_pref_store->ReadPrefs();
|
||||
prefs_factory.set_user_prefs(user_pref_store);
|
||||
} else {
|
||||
prefs_factory.set_user_prefs(
|
||||
new OverlayUserPrefStore(new InMemoryPrefStore));
|
||||
auto user_pref_store =
|
||||
base::MakeRefCounted<OverlayUserPrefStore>(new InMemoryPrefStore);
|
||||
prefs_factory.set_user_prefs(user_pref_store);
|
||||
}
|
||||
local_state_ = prefs_factory.Create(std::move(pref_registry));
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue