mirror of
https://invent.kde.org/system/dolphin
synced 2024-10-28 03:21:56 +00:00
Don't crash when mountpoint is not found
findByPath may return a nullptr, in that case don't access it BUG: 452100
This commit is contained in:
parent
a8966d230c
commit
1041b52c7a
|
@ -45,7 +45,7 @@ QVariant PlacesDataSource::data()
|
|||
auto storageAccess = device.as<Solid::StorageAccess>();
|
||||
if (storageAccess) {
|
||||
auto mountPoint = KMountPoint::currentMountPoints().findByPath(storageAccess->filePath());
|
||||
if (!mountPoint->mountedFrom().startsWith(QLatin1String("kdeconnect@"))) {
|
||||
if (mountPoint && !mountPoint->mountedFrom().startsWith(QLatin1String("kdeconnect@"))) {
|
||||
hasSSHFS = true;
|
||||
continue;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue