fDeviceAddons wasn't maintained correctly. this fixes #2610

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27092 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Jérôme Duval 2008-08-20 23:07:08 +00:00
parent 2a1a5a296f
commit 3658735727

View File

@ -278,6 +278,10 @@ DeviceManager::StopMonitoringDevice(_BDeviceAddOn_ *addon,
j++;
}
if (addon->fMonitoredRefs.IsEmpty()) {
fDeviceAddons.RemoveItem(addon);
}
// stop monitoring if needed
if (!stillMonitored) {
if ((err = RemoveDirectory(&nref, addon)) != B_OK)