Review Request: Fix for clicking on harddisk shortcuts failing to launch mounted directory in a file manager

Dawit Alemayehu adawit at kde.org
Fri Sep 14 17:52:52 BST 2012


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/106446/
-----------------------------------------------------------

Review request for kdelibs and David Faure.


Description
-------

The attached patch fixes mount point look up failures in KAutoMount when the parition is mounted using either a LABEL or a UUID instead of the actual device name. For example, if you have the following entry in your /etc/fstab:

                     'LABEL="KINGSTON" /media/kingston vfat noauto,users,exec 0 0' 

then mounting it will not show the device name LABEL=KINGSTON. Instead, /etc/mtab will return something like:

                     /dev/sdg1 on /media/kingston type vfat (rw,nosuid,nodev,relatime)

Hence, looking for a device named 'LABEL="KINGSTON"' in /etc/mtab will always result in a failure. In case of KAutoMount::slotResult, the SLOT called when mounting is finished, it prints the following warning message:

                      LABEL="KINGSTON" was correctly mounted, but findByDevice() didn't find it. This looks like a bug, please report it
                      on http://bugs.kde.org, together with your /etc/fstab and /etc/mtab lines for this device.

This patch fixes this issue by looking for the mountpoint (/media/kingston) in /etc/mtab when the device cannot be found using its device name.


This addresses bug 247235.
    http://bugs.kde.org/show_bug.cgi?id=247235


Diffs
-----

  kio/kio/kautomount.cpp 9d9789d 

Diff: http://git.reviewboard.kde.org/r/106446/diff/


Testing
-------

- Follow the description in the bug report to create a device shortcut for a mount point that uses a LABEL in /etc/fstab.
- Click on the device shortcut. The device should be mounted and the mount directory opened in a file manager.


Thanks,

Dawit Alemayehu

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20120914/2c57886c/attachment.htm>


More information about the kde-core-devel mailing list