From 95163879aa0ca2442b5decfde08909ee40613bbd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Axel=20D=C3=B6rfler?= Date: Thu, 19 Jul 2007 18:14:38 +0000 Subject: [PATCH] The AutoMounter now also compiles for Haiku again, sorry! git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21668 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/kits/tracker/AutoMounter.cpp | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/src/kits/tracker/AutoMounter.cpp b/src/kits/tracker/AutoMounter.cpp index b99f719c0a..5e3bcddfb0 100644 --- a/src/kits/tracker/AutoMounter.cpp +++ b/src/kits/tracker/AutoMounter.cpp @@ -101,10 +101,11 @@ AutoMounter::_MountVolumes(mount_mode normal, mount_mode removable, class InitialMountVisitor : public BDiskDeviceVisitor { public: InitialMountVisitor(mount_mode normalMode, mount_mode removableMode, - BMessage& previous) + bool initialRescan, BMessage& previous) : fNormalMode(normalMode), fRemovableMode(removableMode), + fInitialRescan(initialRescan), fPrevious(previous) { } @@ -145,11 +146,13 @@ AutoMounter::_MountVolumes(mount_mode normal, mount_mode removable, return false; } - if (partition->Mount() == B_OK) { + BPath path; + if (partition->Mount() == B_OK + && partition->GetMountPoint(&path) == B_OK) { // notify Tracker that a new volume has been started BMessage note(kVolumeMounted); - note.AddString("path", partition->MountedAt()); - note.AddBool("initial rescan", sInitialRescan); + note.AddString("path", path.Path()); + note.AddBool("initial rescan", fInitialRescan); be_app->PostMessage(¬e); } return false; @@ -158,8 +161,9 @@ AutoMounter::_MountVolumes(mount_mode normal, mount_mode removable, private: mount_mode fNormalMode; mount_mode fRemovableMode; + bool fInitialRescan; BMessage& fPrevious; - } visitor(normal, removable, fSettings); + } visitor(normal, removable, initialRescan, fSettings); BDiskDeviceList devices; status_t status = devices.Fetch();