diff options
Diffstat (limited to 'astro/qmapshack/files/patch-src_qmapshack_device_CDeviceWatcherLinux.cpp')
-rw-r--r-- | astro/qmapshack/files/patch-src_qmapshack_device_CDeviceWatcherLinux.cpp | 27 |
1 files changed, 25 insertions, 2 deletions
diff --git a/astro/qmapshack/files/patch-src_qmapshack_device_CDeviceWatcherLinux.cpp b/astro/qmapshack/files/patch-src_qmapshack_device_CDeviceWatcherLinux.cpp index 349802a14a16..06929a6cacbe 100644 --- a/astro/qmapshack/files/patch-src_qmapshack_device_CDeviceWatcherLinux.cpp +++ b/astro/qmapshack/files/patch-src_qmapshack_device_CDeviceWatcherLinux.cpp @@ -1,6 +1,6 @@ ---- src/qmapshack/device/CDeviceWatcherLinux.cpp.orig 2023-07-20 14:13:59 UTC +--- src/qmapshack/device/CDeviceWatcherLinux.cpp.orig 2025-07-04 12:38:57 UTC +++ src/qmapshack/device/CDeviceWatcherLinux.cpp -@@ -47,6 +47,10 @@ void CDeviceWatcherLinux::slotDeviceAdded(const QDBusO +@@ -97,6 +97,10 @@ void CDeviceWatcherLinux::slotDeviceAdded(const QDBusO QDBusInterface* blockIface = new QDBusInterface("org.freedesktop.UDisks2", path.path(), "org.freedesktop.UDisks2.Block", QDBusConnection::systemBus(), this); QDBusObjectPath drive_object = blockIface->property("Drive").value<QDBusObjectPath>(); @@ -11,3 +11,26 @@ QString idLabel = blockIface->property("IdLabel").toString().toUpper(); // read vendor string attached to drive +@@ -207,14 +211,6 @@ QString CDeviceWatcherLinux::readMountPoint(const QStr + + const QDBusMessage& reply = QDBusConnection::systemBus().call(message); + +-#if defined(Q_OS_FREEBSD) +- // this is probably broken code and needs to be fixed +- for (const QVariant& arg : reply.arguments()) { +- if (!arg.value<QDBusVariant>().variant().value<QStringList>().isEmpty()) { +- points.append(arg.value<QDBusVariant>().variant().value<QStringList>().first()); +- } +- } +-#else + QStringList mountPoints; + + for (const QVariant& arg : reply.arguments()) { +@@ -246,7 +242,6 @@ QString CDeviceWatcherLinux::readMountPoint(const QStr + } + dbusArg.endArray(); + } +-#endif + + if (!mountPoints.isEmpty()) { + return mountPoints.first(); |