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

Unified Diff: chrome/browser/profiles/profile_impl.h

Issue 8591024: Correct the order of destruction of ProfileImplIOData and ExtensionProcessManager. This was causi... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/profiles/off_the_record_profile_impl.cc ('k') | chrome/browser/profiles/profile_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/profiles/profile_impl.h
===================================================================
--- chrome/browser/profiles/profile_impl.h (revision 111186)
+++ chrome/browser/profiles/profile_impl.h (working copy)
@@ -198,6 +198,13 @@
FilePath path_;
FilePath base_cache_path_;
+
+ // !!! BIG HONKING WARNING !!!
+ // The order of the members below is important. Do not change it unless
+ // you know what you're doing. Also, if adding a new member here make sure
+ // that the declaration occurs AFTER things it depends on as destruction
+ // happens in reverse order of declaration.
+
scoped_ptr<ExtensionPrefValueMap> extension_pref_value_map_;
// Keep |prefs_| on top for destruction order because |extension_prefs_|,
// |net_pref_observer_|, |web_resource_service_|, and |io_data_| store
@@ -211,9 +218,16 @@
scoped_ptr<ExtensionPrefs> extension_prefs_;
scoped_ptr<ExtensionService> extension_service_;
scoped_refptr<UserScriptMaster> user_script_master_;
+
+ ProfileImplIOData::Handle io_data_;
+
scoped_refptr<ExtensionDevToolsManager> extension_devtools_manager_;
// extension_info_map_ needs to outlive extension_process_manager_.
scoped_refptr<ExtensionInfoMap> extension_info_map_;
+ // |extension_process_manager_| must be destroyed before |io_data_|.
+ // While |extension_process_manager_| still lives, we handle incoming
+ // resource requests from extension processes and those require access
+ // to the ResourceContext owned by |io_data_|.
scoped_ptr<ExtensionProcessManager> extension_process_manager_;
scoped_refptr<ExtensionMessageService> extension_message_service_;
scoped_ptr<ExtensionEventRouter> extension_event_router_;
@@ -231,8 +245,6 @@
scoped_ptr<ProfileSyncComponentsFactory> profile_sync_factory_;
scoped_ptr<ProfileSyncService> sync_service_;
- ProfileImplIOData::Handle io_data_;
-
scoped_ptr<SSLConfigServiceManager> ssl_config_service_manager_;
scoped_refptr<HostContentSettingsMap> host_content_settings_map_;
« no previous file with comments | « chrome/browser/profiles/off_the_record_profile_impl.cc ('k') | chrome/browser/profiles/profile_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698