Fix DisableReason handling in ProfileSyncService::Initialize
ProfileSyncService::Initialize used to early-out if DISABLE_REASON_PLATFORM_OVERRIDE or DISABLE_REASON_ENTERPRISE_POLICY were present. However: - In practice, platform_sync_allowed_provider_ isn't set at this point, so DISABLE_REASON_PLATFORM_OVERRIDE will never occur. Even if it did, calling StopImpl(KEEP_DATA) at this point (before |engine_| exists) does nothing. - Both disable reasons can disappear during Chrome's lifetime, in which case ProfileSyncService is left in a half-initialized state. In particular, it won't be listening for auth events. This CL removes handling for DISABLE_REASON_PLATFORM_OVERRIDE, and does not early-out anymore for DISABLE_REASON_ENTERPRISE_POLICY. Bug: 870683 Change-Id: I354629deaa42a782e10658190c84e967fee593a3 Reviewed-on: https://chromium-review.googlesource.com/1162236Reviewed-by:Mikel Astiz <mastiz@chromium.org> Commit-Queue: Marc Treib <treib@chromium.org> Cr-Commit-Position: refs/heads/master@{#580818}
Showing
Please register or sign in to comment