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

Unified Diff: device/base/device_monitor_linux.cc

Issue 2482463002: Remove DeviceMonitorLinux::WillDestroyCurrentMessageLoop(). (Closed)
Patch Set: CR achuithb #24 Created 4 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 | « device/base/device_monitor_linux.h ('k') | device/hid/hid_service.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: device/base/device_monitor_linux.cc
diff --git a/device/base/device_monitor_linux.cc b/device/base/device_monitor_linux.cc
index 179b6f5bae295812a64370145dd0c79445e049ef..67ce6b8af3a8de841344944d9ef5dffa62ed9134 100644
--- a/device/base/device_monitor_linux.cc
+++ b/device/base/device_monitor_linux.cc
@@ -29,7 +29,6 @@ base::LazyInstance<DeviceMonitorLinux>::Leaky g_device_monitor_linux =
DeviceMonitorLinux::DeviceMonitorLinux() : monitor_fd_(-1) {
base::ThreadRestrictions::AssertIOAllowed();
- base::MessageLoop::current()->AddDestructionObserver(this);
udev_.reset(udev_new());
if (!udev_) {
@@ -100,12 +99,6 @@ void DeviceMonitorLinux::Enumerate(const EnumerateCallback& callback) {
}
}
-void DeviceMonitorLinux::WillDestroyCurrentMessageLoop() {
- DCHECK(thread_checker_.CalledOnValidThread());
- for (auto& observer : observers_)
- observer.WillDestroyMonitorMessageLoop();
-}
-
DeviceMonitorLinux::~DeviceMonitorLinux() {
// A leaky LazyInstance is never destroyed.
NOTREACHED();
« no previous file with comments | « device/base/device_monitor_linux.h ('k') | device/hid/hid_service.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698