Commit ac427878 authored by Sergey Kuznetsov's avatar Sergey Kuznetsov Committed by Commit Bot

Initialize pref_model_associator_client_ with nullptr.

Some clients (in tests) doesn't call SetPrefModelAssociatorClient.
This leaves pref_model_associator_client_ in uninitialized state.
And CreateSyncable call creates PrefServiceSyncable with
invalid client_ pointer.

Change-Id: I89b310729ef817d75374d2fe66245d7538665e5b
Reviewed-on: https://chromium-review.googlesource.com/923968Reviewed-by: default avatarBernhard Bauer <bauerb@chromium.org>
Commit-Queue: Bernhard Bauer <bauerb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#537645}
parent ac9ef193
...@@ -50,7 +50,7 @@ class PrefServiceSyncableFactory : public PrefServiceFactory { ...@@ -50,7 +50,7 @@ class PrefServiceSyncableFactory : public PrefServiceFactory {
std::unique_ptr<PrefValueStore::Delegate> delegate = nullptr); std::unique_ptr<PrefValueStore::Delegate> delegate = nullptr);
private: private:
PrefModelAssociatorClient* pref_model_associator_client_; PrefModelAssociatorClient* pref_model_associator_client_ = nullptr;
DISALLOW_COPY_AND_ASSIGN(PrefServiceSyncableFactory); DISALLOW_COPY_AND_ASSIGN(PrefServiceSyncableFactory);
}; };
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment