[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: kdeutils/kdf
From: David Faure <faure () kde ! org>
Date: 2004-06-02 10:30:26
Message-ID: 20040602103026.3804D12661 () office ! kde ! org
[Download RAW message or body]
CVS commit by faure:
Also follow symlinks in the mountpoint
CCMAIL: 22319-done@bugs.kde.org
M +4 -3 disklist.cpp 1.36
M +6 -0 disks.cpp 1.30
M +2 -0 disks.h 1.10
--- kdeutils/kdf/disklist.cpp #1.35:1.36
@@ -381,5 +381,5 @@ void DiskList::deleteAllMountedAt(const
void DiskList::replaceDeviceEntry(DiskEntry *disk)
{
- //kdDebug() << k_funcinfo << disk->deviceRealName() << " " << disk->mountPoint() << endl;
+ //kdDebug() << k_funcinfo << disk->deviceRealName() << " " << disk->realMountPoint() << endl;
//
@@ -396,4 +396,5 @@ void DiskList::replaceDeviceEntry(DiskEn
QString deviceRealName = disk->deviceRealName();
+ QString realMountPoint = disk->realMountPoint();
int pos = -1;
@@ -404,5 +405,5 @@ void DiskList::replaceDeviceEntry(DiskEn
if( res == 0 )
{
- res = disk->mountPoint().compare( item->mountPoint() );
+ res = realMountPoint.compare( item->realMountPoint() );
}
if( res == 0 )
--- kdeutils/kdf/disks.cpp #1.29:1.30
@@ -284,4 +284,10 @@ void DiskEntry::setMountPoint(const QStr
}
+QString DiskEntry::realMountPoint() const
+{
+ QDir dir( mountedOn );
+ return dir.canonicalPath();
+}
+
void DiskEntry::setMountOptions(const QString & mountOptions)
{
--- kdeutils/kdf/disks.h #1.9:1.10
@@ -51,4 +51,6 @@ public:
QString mountPoint() const { return mountedOn; }
QString mountOptions() const { return options; }
+ // The real device (in case deviceName() is a symlink)
+ QString realMountPoint() const;
/**
* sets the used mountCommand for the actual DiskEntry.
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic