https://bugs.kde.org/show_bug.cgi?id=349617

Ahmad Samir <a.samir...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Version Fixed In|                            |5.84
         Resolution|---                         |FIXED
      Latest Commit|                            |https://invent.kde.org/fram
                   |                            |eworks/solid/commit/ef0b0df
                   |                            |a00b1de70c6d8e6913bbfdb79e7
                   |                            |d3d1b6
             Status|ASSIGNED                    |RESOLVED

--- Comment #15 from Ahmad Samir <a.samir...@gmail.com> ---
Git commit ef0b0dfa00b1de70c6d8e6913bbfdb79e7d3d1b6 by Ahmad Samir.
Committed on 23/06/2021 at 09:16.
Pushed by ahmadsamir into branch 'master'.

Find the base mount point of a partition that has bind mounts

With bind mounts on Linux, UDisks returns a 'MountPoints' property that could
include several paths, try to get the actual mount point of the partition
and ignore bind mounts.

Inspired by the approach used by GNOME's gio, use libmount to parse
"/proc/self/mountinfo" and check the path returned by mnt_fs_get_root(), for
the base partition this should return "/", for bind mounts it returns a dir
e.g. /mnt/dirA/.

This fixes a bug where clicking a Device icon in the Places panel could open
the path of one of the bind mounts instead of the actual/base partition mount
point, which is confusing to say the least.

For more details:
https://invent.kde.org/frameworks/solid/-/merge_requests/37

https://gitlab.gnome.org/GNOME/glib/-/issues/1271#note_352412
https://gitlab.gnome.org/GNOME/glib/-/commit/e1fa5ffb91e74376394fe17612015d44fec82366
https://github.com/storaged-project/udisks/issues/478
FIXED-IN: 5.84

M  +5    -0    CMakeLists.txt
M  +4    -0    src/solid/devices/backends/udisks2/CMakeLists.txt
M  +53   -8    src/solid/devices/backends/udisks2/udisksstorageaccess.cpp
M  +2    -0    src/solid/devices/config-solid.h.cmake

https://invent.kde.org/frameworks/solid/commit/ef0b0dfa00b1de70c6d8e6913bbfdb79e7d3d1b6

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to