Chromium Code Reviews
[email protected] (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(244)

Issue 12310100: Initialize BrowserPolicyConnector after the IOThread is created. (Closed)

Created:
7 years, 10 months ago by Joao da Silva
Modified:
7 years, 9 months ago
CC:
chromium-reviews
Base URL:
http://git.chromium.org/chromium/src.git@master
Visibility:
Public.

Description

Initialize BrowserPolicyConnector after the IOThread is created. The import process on Windows spawns a subprocess and spins a nested message loop waiting for it to complete. If this subprocess takes longer than 5 seconds then the message loop will execute a delayed initialization task of the policy code, that grabs the system request context; however, since the IOThread hasn't been created yet this leads to a crash. BUG=177843 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=184967

Patch Set 1 #

Total comments: 2

Patch Set 2 : wip #

Patch Set 3 : fixed tests, fixed order of initialization of things #

Total comments: 16

Patch Set 4 : wrap chromeos-only code with ifdefs #

Patch Set 5 : addressed comments #

Patch Set 6 : Fixed desktop test #

Patch Set 7 : fixed broken test #

Unified diffs Side-by-side diffs Delta from patch set Stats (+157 lines, -131 lines) Patch
M chrome/browser/browser_process_impl.cc View 1 2 3 4 2 chunks +10 lines, -2 lines 0 comments Download
M chrome/browser/chromeos/login/login_utils_browsertest.cc View 1 2 3 4 5 6 2 chunks +4 lines, -2 lines 0 comments Download
M chrome/browser/chromeos/ui/idle_logout_dialog_view_browsertest.cc View 1 2 3 4 5 6 3 chunks +10 lines, -18 lines 0 comments Download
M chrome/browser/policy/async_policy_provider.cc View 1 2 3 4 1 chunk +2 lines, -1 line 0 comments Download
M chrome/browser/policy/browser_policy_connector.h View 1 2 3 4 5 chunks +13 lines, -8 lines 0 comments Download
M chrome/browser/policy/browser_policy_connector.cc View 1 2 3 4 15 chunks +97 lines, -94 lines 0 comments Download
M chrome/browser/policy/user_policy_signin_service_unittest.cc View 1 2 3 4 5 6 4 chunks +7 lines, -3 lines 0 comments Download
M chrome/test/base/testing_browser_process.cc View 1 2 3 3 chunks +14 lines, -3 lines 0 comments Download

Messages

Total messages: 17 (0 generated)
Joao da Silva
Please review. This will likely be merged to 26.
7 years, 10 months ago (2013-02-25 09:43:22 UTC) #1
Mattias Nissler (ping if slow)
cloud policy browser_test is broken apparently. https://codereview.chromium.org/12310100/diff/1/chrome/browser/policy/browser_policy_connector.cc File chrome/browser/policy/browser_policy_connector.cc (right): https://codereview.chromium.org/12310100/diff/1/chrome/browser/policy/browser_policy_connector.cc#newcode148 chrome/browser/policy/browser_policy_connector.cc:148: void BrowserPolicyConnector::Init() { ...
7 years, 10 months ago (2013-02-25 18:44:41 UTC) #2
Joao da Silva
@Mattias: PTAL @Jochen: please review the chrome/ changes
7 years, 10 months ago (2013-02-26 14:07:14 UTC) #3
Mattias Nissler (ping if slow)
LGTM https://codereview.chromium.org/12310100/diff/7001/chrome/browser/browser_process_impl.cc File chrome/browser/browser_process_impl.cc (right): https://codereview.chromium.org/12310100/diff/7001/chrome/browser/browser_process_impl.cc#newcode848 chrome/browser/browser_process_impl.cc:848: // the main BrowserThreads are ready. All of ...
7 years, 10 months ago (2013-02-26 14:22:00 UTC) #4
jochen (gone - plz use gerrit)
lgtm https://codereview.chromium.org/12310100/diff/7001/chrome/browser/chromeos/login/login_utils_browsertest.cc File chrome/browser/chromeos/login/login_utils_browsertest.cc (right): https://codereview.chromium.org/12310100/diff/7001/chrome/browser/chromeos/login/login_utils_browsertest.cc#newcode269 chrome/browser/chromeos/login/login_utils_browsertest.cc:269: g_browser_process->system_request_context()); why are you using g_browser_process and not ...
7 years, 10 months ago (2013-02-26 14:23:04 UTC) #5
Joao da Silva
Thanks for the comments! https://codereview.chromium.org/12310100/diff/7001/chrome/browser/browser_process_impl.cc File chrome/browser/browser_process_impl.cc (right): https://codereview.chromium.org/12310100/diff/7001/chrome/browser/browser_process_impl.cc#newcode848 chrome/browser/browser_process_impl.cc:848: // the main BrowserThreads are ...
7 years, 10 months ago (2013-02-26 16:09:00 UTC) #6
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/[email protected]/12310100/13001
7 years, 10 months ago (2013-02-26 16:09:43 UTC) #7
commit-bot: I haz the power
Retried try job too often on linux_rel for step(s) unit_tests http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=linux_rel&number=102007
7 years, 10 months ago (2013-02-26 17:07:06 UTC) #8
Joao da Silva
@Mattias: changed chrome/browser/policy/user_policy_signin_service_unittest.cc to use an IO instead of a UI loop, this fixes a ...
7 years, 10 months ago (2013-02-26 18:20:10 UTC) #9
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/[email protected]/12310100/3004
7 years, 10 months ago (2013-02-26 18:20:33 UTC) #10
commit-bot: I haz the power
Retried try job too often on win7_aura for step(s) browser_tests http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=win7_aura&number=14076
7 years, 10 months ago (2013-02-26 19:27:44 UTC) #11
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/[email protected]/12310100/3004
7 years, 10 months ago (2013-02-26 19:33:05 UTC) #12
commit-bot: I haz the power
Retried try job too often on linux_chromeos for step(s) browser_tests http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=linux_chromeos&number=87658
7 years, 10 months ago (2013-02-26 22:32:36 UTC) #13
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/[email protected]/12310100/3004
7 years, 10 months ago (2013-02-27 07:27:13 UTC) #14
commit-bot: I haz the power
Retried try job too often on linux_chromeos for step(s) browser_tests http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=linux_chromeos&number=87872
7 years, 10 months ago (2013-02-27 09:49:42 UTC) #15
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/[email protected]/12310100/3008
7 years, 9 months ago (2013-02-27 12:47:20 UTC) #16
commit-bot: I haz the power
7 years, 9 months ago (2013-02-27 16:15:22 UTC) #17
Message was sent while issue was closed.
Change committed as 184967

Powered by Google App Engine
This is Rietveld 408576698