Index: chrome/browser/storage_monitor/storage_monitor.cc |
diff --git a/chrome/browser/storage_monitor/storage_monitor.cc b/chrome/browser/storage_monitor/storage_monitor.cc |
index 6d27d3bdfc41534b2230ecf419f39675faa089cc..d4123b9f1f2f678ee698fad3596ab87a519c5252 100644 |
--- a/chrome/browser/storage_monitor/storage_monitor.cc |
+++ b/chrome/browser/storage_monitor/storage_monitor.cc |
@@ -6,13 +6,12 @@ |
#include "base/stl_util.h" |
#include "base/strings/utf_string_conversions.h" |
+#include "chrome/browser/browser_process.h" |
#include "chrome/browser/storage_monitor/removable_storage_observer.h" |
#include "chrome/browser/storage_monitor/transient_device_ids.h" |
namespace chrome { |
-static StorageMonitor* g_storage_monitor = NULL; |
- |
StorageMonitor::Receiver::~Receiver() { |
} |
@@ -46,7 +45,7 @@ void StorageMonitor::ReceiverImpl::MarkInitialized() { |
} |
StorageMonitor* StorageMonitor::GetInstance() { |
- return g_storage_monitor; |
+ return g_browser_process->storage_monitor(); |
} |
std::vector<StorageInfo> StorageMonitor::GetAllAvailableStorages() const { |
@@ -117,18 +116,9 @@ StorageMonitor::StorageMonitor() |
initialized_(false), |
transient_device_ids_(new TransientDeviceIds) { |
receiver_.reset(new ReceiverImpl(this)); |
- |
- DCHECK(!g_storage_monitor); |
- g_storage_monitor = this; |
} |
StorageMonitor::~StorageMonitor() { |
- g_storage_monitor = NULL; |
-} |
- |
-// static |
-void StorageMonitor::RemoveSingletonForTesting() { |
- g_storage_monitor = NULL; |
} |
StorageMonitor::Receiver* StorageMonitor::receiver() const { |