Sophie

Sophie

distrib > Mandriva > 2009.0 > i586 > by-pkgid > 901b66721cd8b67ee1adbc6604574c15 > files > 21

kdebase-3.5.10-6mdv2009.0.src.rpm

--- kdebase-3.5.7/kioslave/media/mediamanager/halbackend.cpp.fix_fstab_unmount	2007-09-28 15:30:18.000000000 -0300
+++ kdebase-3.5.7/kioslave/media/mediamanager/halbackend.cpp	2007-09-28 15:31:27.000000000 -0300
@@ -290,6 +290,11 @@ void HALBackend::AddDevice(const char *u
 
 void HALBackend::RemoveDevice(const char *udi)
 {
+    // if the device is being handle by fstab, we have to unmount it
+    const Medium* medium = m_mediaList.findById(udi);
+    if (medium && !isInFstab(medium).isNull())
+        unmount(udi);
+
     m_mediaList.removeMedium(udi, true);
 }