summaryrefslogtreecommitdiffstats
path: root/chrome/browser/browser_process_impl.h
diff options
context:
space:
mode:
authorjkummerow@chromium.org <jkummerow@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-01-05 09:38:07 +0000
committerjkummerow@chromium.org <jkummerow@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-01-05 09:38:07 +0000
commitf2a893c2215a31a99e95b25b2f93000fdefc7a5b (patch)
treebf7ec4f5f964a45bb7c9aa0ea09e301f7cb30d2d /chrome/browser/browser_process_impl.h
parent3ab9898b32d19cada0c583d6deb1206c4e680dd7 (diff)
downloadchromium_src-f2a893c2215a31a99e95b25b2f93000fdefc7a5b.zip
chromium_src-f2a893c2215a31a99e95b25b2f93000fdefc7a5b.tar.gz
chromium_src-f2a893c2215a31a99e95b25b2f93000fdefc7a5b.tar.bz2
Lifecycle management for PolicyProviders
The ConfigurationPolicyProviderKeeper (and therefore the individual ConfigurationPolicyProviders) is now a member variable of the BrowserProcess instead of a singleton. This fixes memory leaks at the cost of slightly more complicated shutdown (the PolicyProviders must die while the file thread is still alive, but the preference system observing the providers for policy changes lives longer than that). BUG=66054, 66102 TEST=existing unit tests; valgrind Review URL: http://codereview.chromium.org/5962016 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@70496 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/browser_process_impl.h')
-rw-r--r--chrome/browser/browser_process_impl.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/chrome/browser/browser_process_impl.h b/chrome/browser/browser_process_impl.h
index d5d3b51..8ec6f81 100644
--- a/chrome/browser/browser_process_impl.h
+++ b/chrome/browser/browser_process_impl.h
@@ -1,4 +1,4 @@
-// Copyright (c) 2010 The Chromium Authors. All rights reserved.
+// Copyright (c) 2011 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
@@ -61,6 +61,8 @@ class BrowserProcessImpl : public BrowserProcess,
virtual SidebarManager* sidebar_manager();
virtual Clipboard* clipboard();
virtual NotificationUIManager* notification_ui_manager();
+ virtual policy::ConfigurationPolicyProviderKeeper*
+ configuration_policy_provider_keeper();
virtual IconManager* icon_manager();
virtual ThumbnailGenerator* GetThumbnailGenerator();
virtual AutomationProviderList* InitAutomationProviderList();
@@ -179,6 +181,10 @@ class BrowserProcessImpl : public BrowserProcess,
bool created_sidebar_manager_;
scoped_refptr<SidebarManager> sidebar_manager_;
+ bool created_configuration_policy_provider_keeper_;
+ scoped_ptr<policy::ConfigurationPolicyProviderKeeper>
+ configuration_policy_provider_keeper_;
+
scoped_refptr<printing::PrintPreviewTabController>
print_preview_tab_controller_;