diff options
author | eroman@chromium.org <eroman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-12-08 18:35:14 +0000 |
---|---|---|
committer | eroman@chromium.org <eroman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-12-08 18:35:14 +0000 |
commit | ec86bea44a17187127f3b5a07524dc533d07705c (patch) | |
tree | e81b90e5151fb3b29d345abb4408bf0e1288d099 /chrome/browser/browser_shutdown.cc | |
parent | 53a8ff8ea2865783e63ffa3d8388a5b023353b39 (diff) | |
download | chromium_src-ec86bea44a17187127f3b5a07524dc533d07705c.zip chromium_src-ec86bea44a17187127f3b5a07524dc533d07705c.tar.gz chromium_src-ec86bea44a17187127f3b5a07524dc533d07705c.tar.bz2 |
Refactor: Eliminte locking from PrefetchObserver and DnsMaster in favor of making these classes non-threadsafe.
Conceptually, PrefetchObserver and DnsMaster live on the IO thread, and their methods can only be called from the IO thread.
In the cases where calls do need to be made from the UI thread, we post a task to be run on the IO loop and return without blocking.
The only time where we block is during shutdown, when we must wait on the IO thread to get us the startup list and referral list.
BUG=25335
Review URL: http://codereview.chromium.org/300032
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@34066 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/browser_shutdown.cc')
-rw-r--r-- | chrome/browser/browser_shutdown.cc | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/chrome/browser/browser_shutdown.cc b/chrome/browser/browser_shutdown.cc index 474410f..520ead7 100644 --- a/chrome/browser/browser_shutdown.cc +++ b/chrome/browser/browser_shutdown.cc @@ -105,13 +105,7 @@ void Shutdown() { PrefService* prefs = g_browser_process->local_state(); - chrome_browser_net::SaveHostNamesForNextStartup(prefs); - // TODO(jar): Trimming should be done more regularly, such as every 48 hours - // of physical time, or perhaps after 48 hours of running (excluding time - // between sessions possibly). - // For now, we'll just trim at shutdown. - chrome_browser_net::TrimSubresourceReferrers(); - chrome_browser_net::SaveSubresourceReferrers(prefs); + chrome_browser_net::SaveDnsPrefetchStateForNextStartupAndTrim(prefs); MetricsService* metrics = g_browser_process->metrics_service(); if (metrics) { |