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

Issue 11667006: Create a list of policy changes before notifying observers (Closed)

Created:
8 years ago by Andrew T Wilson (Slow)
Modified:
7 years, 11 months ago
Reviewers:
Joao da Silva
CC:
chromium-reviews
Visibility:
Public.

Description

Notify policy change observers via a task This prevents unexpected reentrancy in OnUpdatePolicy() in the case that an observer changes policy (leading to a recursive call to OnUpdatePolicy()). This avoids a crash that happens if we change the SyncDisabled policy, since this signs out the user and modifies policy while we are still iterating through the PolicyBundles in MergeAndTriggerUpdates(). BUG=155486 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=175797

Patch Set 1 #

Patch Set 2 : Added unit tests. #

Patch Set 3 : Fix lint error/merge to ToT #

Total comments: 6

Patch Set 4 : Review feedback (now uses task queue to notify observers) #

Patch Set 5 : Fixed clang compilation err. #

Patch Set 6 : Fixed browser tests. #

Patch Set 7 : Rebase to ToT #

Total comments: 12

Patch Set 8 : More review feedback. #

Patch Set 9 : Moar test fixes. #

Patch Set 10 : Moar test fixes #

Patch Set 11 : Another ToT merge #

Unified diffs Side-by-side diffs Delta from patch set Stats (+267 lines, -118 lines) Patch
M chrome/browser/policy/configuration_policy_pref_store_unittest.cc View 1 2 3 4 5 6 7 39 chunks +49 lines, -40 lines 0 comments Download
M chrome/browser/policy/network_configuration_updater_unittest.cc View 1 2 3 4 5 6 7 6 chunks +13 lines, -4 lines 0 comments Download
M chrome/browser/policy/policy_browsertest.cc View 1 2 3 4 5 6 7 8 9 10 39 chunks +48 lines, -40 lines 0 comments Download
M chrome/browser/policy/policy_prefs_browsertest.cc View 1 2 3 4 5 6 7 8 9 10 5 chunks +12 lines, -5 lines 0 comments Download
M chrome/browser/policy/policy_service_impl.h View 1 2 3 4 5 6 7 3 chunks +24 lines, -2 lines 0 comments Download
M chrome/browser/policy/policy_service_impl.cc View 1 2 3 4 5 6 7 2 chunks +45 lines, -3 lines 0 comments Download
M chrome/browser/policy/policy_service_impl_unittest.cc View 1 2 3 4 5 6 7 20 chunks +76 lines, -24 lines 0 comments Download

Messages

Total messages: 20 (0 generated)
Andrew T Wilson (Slow)
PTAL
8 years ago (2012-12-21 17:47:16 UTC) #1
Joao da Silva
I'd prefer posting MergeAndTriggerUpdates from its current call sites (or adding a helper PostMergeAndTriggerUpdates call), ...
8 years ago (2012-12-22 21:42:00 UTC) #2
Andrew T Wilson (Slow)
PTAL. I've changed this to issue tasks for the various policy notifications rather than creating ...
7 years, 11 months ago (2013-01-04 15:54:48 UTC) #3
Joao da Silva
LGTM after fixing DisableScreenshotsFeedback and the nits. Re DisableScreenshotsFeedback: I think SetScreenshotPolicy() in policy_browsertest.cc needs ...
7 years, 11 months ago (2013-01-07 09:23:51 UTC) #4
Andrew T Wilson (Slow)
https://codereview.chromium.org/11667006/diff/12007/chrome/browser/policy/configuration_policy_pref_store_unittest.cc File chrome/browser/policy/configuration_policy_pref_store_unittest.cc (right): https://codereview.chromium.org/11667006/diff/12007/chrome/browser/policy/configuration_policy_pref_store_unittest.cc#newcode48 chrome/browser/policy/configuration_policy_pref_store_unittest.cc:48: ConfigurationPolicyPrefStoreTest() : loop_(MessageLoop::TYPE_UI) { On 2013/01/07 09:23:52, Joao da ...
7 years, 11 months ago (2013-01-07 14:11:32 UTC) #5
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/atwilson@chromium.org/11667006/31002
7 years, 11 months ago (2013-01-07 14:11:50 UTC) #6
commit-bot: I haz the power
Retried try job too often on ios_dbg_simulator for step(s) sync_unit_tests, unit_tests
7 years, 11 months ago (2013-01-07 14:27:45 UTC) #7
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/atwilson@chromium.org/11667006/31002
7 years, 11 months ago (2013-01-07 14:33:11 UTC) #8
commit-bot: I haz the power
Retried try job too often on ios_dbg_simulator for step(s) sync_unit_tests, unit_tests
7 years, 11 months ago (2013-01-07 14:41:29 UTC) #9
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/atwilson@chromium.org/11667006/31002
7 years, 11 months ago (2013-01-07 17:10:24 UTC) #10
commit-bot: I haz the power
Retried try job too often on win_aura for step(s) interactive_ui_tests
7 years, 11 months ago (2013-01-07 19:04:54 UTC) #11
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/atwilson@chromium.org/11667006/31002
7 years, 11 months ago (2013-01-08 07:59:41 UTC) #12
commit-bot: I haz the power
Retried try job too often on win_rel for step(s) browser_tests
7 years, 11 months ago (2013-01-08 12:02:11 UTC) #13
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/atwilson@chromium.org/11667006/31002
7 years, 11 months ago (2013-01-08 13:01:48 UTC) #14
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/atwilson@chromium.org/11667006/38005
7 years, 11 months ago (2013-01-08 14:44:48 UTC) #15
commit-bot: I haz the power
Retried try job too often on linux_chromeos for step(s) browser_tests
7 years, 11 months ago (2013-01-08 17:37:07 UTC) #16
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/atwilson@chromium.org/11667006/38005
7 years, 11 months ago (2013-01-09 12:12:41 UTC) #17
commit-bot: I haz the power
Failed to apply patch for chrome/browser/policy/policy_browsertest.cc: While running patch -p1 --forward --force --no-backup-if-mismatch; patching file ...
7 years, 11 months ago (2013-01-09 12:12:47 UTC) #18
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/atwilson@chromium.org/11667006/53001
7 years, 11 months ago (2013-01-09 12:34:47 UTC) #19
commit-bot: I haz the power
7 years, 11 months ago (2013-01-09 14:28:14 UTC) #20
Message was sent while issue was closed.
Change committed as 175797

Powered by Google App Engine
This is Rietveld 408576698