KMountPoint doesn't determine the correct mount point, if there are bind mounts. This breaks the Trash handling, files from other devices are moved to the home directory trash folder instead of the trash folder on the other device. dd if=/dev/zero of=/tmp/test-disk1 bs=1024 count=10000 dd if=/dev/zero of=/tmp/test-disk2 bs=1024 count=10000 mkfs.ext4 /tmp/test-disk1 mkfs.ext4 /tmp/test-disk2 mkdir /mnt/test-disk1 mkdir /mnt/test-disk2 mount -o loop /tmp/test-disk1 /mnt/test-disk1 mount -o loop /tmp/test-disk2 /mnt/test-disk2 mkdir -p /mnt/test-disk1/aaa mkdir -p /mnt/test-disk2/aaa/bbb touch /mnt/test-disk2/aaa/bbb/file mount --bind /mnt/test-disk2/aaa/bbb /mnt/test-disk1/aaa Stat: # stat /mnt/test-disk1 File: /mnt/test-disk1 Size: 1024 Blocks: 2 IO Block: 1024 directory Device: 701h/1793d Inode: 2 Links: 4 # stat /mnt/test-disk2 File: /mnt/test-disk2 Size: 1024 Blocks: 2 IO Block: 1024 directory Device: 702h/1794d Inode: 2 Links: 4 # stat /mnt/test-disk1/aaa/file File: /mnt/test-disk1/aaa/file Size: 0 Blocks: 0 IO Block: 1024 regular empty file Device: 702h/1794d Inode: 13 Links: 1 ------------------------------------------------------ KMountPoint::currentMountPoints(): #include <QDebug> #include <KMountPoint> int main() { const QString origPath = "/mnt/test-disk1/aaa/file"; KMountPoint::Ptr mp = KMountPoint::currentMountPoints().findByPath(origPath); qDebug() << mp->mountPoint(); } ------------------------------------------------------- Which returns: "/mnt/test-disk1/aaa", while the file resides on test-disk2. People complaining about Trash not working correctly: https://www.reddit.com/r/kde/comments/59cefq/are_there_options_to_manage_how_the_trash_is/
Bug 349617 is related. If Solid was able to report the correct mount point for devices, it might make sense to take the device id from the file and use Solid to determine the mount paths based on the device id.
Thank you for reporting this issue in KDE software. As it has been a while since this issue was reported, can we please ask you to see if you can reproduce the issue with a recent software version? If you can reproduce the issue, please change the status to "REPORTED" when replying. Thank you!
Dear Bug Submitter, This bug has been in NEEDSINFO status with no change for at least 15 days. Please provide the requested information as soon as possible and set the bug status as REPORTED. Due to regular bug tracker maintenance, if the bug is still in NEEDSINFO status with no change in 30 days the bug will be closed as RESOLVED > WORKSFORME due to lack of needed information. For more information about our bug triaging procedures please read the wiki located here: https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging If you have already provided the requested information, please mark the bug as REPORTED so that the KDE team knows that the bug is ready to be confirmed. Thank you for helping us make KDE software even better for everyone!
This bug has been in NEEDSINFO status with no change for at least 30 days. The bug is now closed as RESOLVED > WORKSFORME due to lack of needed information. For more information about our bug triaging procedures please read the wiki located here: https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging Thank you for helping us make KDE software even better for everyone!