From: Christian Kamm Date: Tue, 18 Dec 2018 09:31:17 +0000 (+0100) Subject: Vfs plugins: Available plugins must load X-Git-Tag: archive/raspbian/3.16.7-1_deb13u1+rpi1~1^2~12^2~21^2~468^2~368 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=bdfda460e67a57d4976a35ddc752b3c7c1352b0d;p=nextcloud-desktop.git Vfs plugins: Available plugins must load A plugin that can't be loaded due to dependency issues should not be considered as available. --- diff --git a/src/common/vfs.cpp b/src/common/vfs.cpp index a1ad02efe..4f3b6fadc 100644 --- a/src/common/vfs.cpp +++ b/src/common/vfs.cpp @@ -107,6 +107,13 @@ bool OCC::isVfsPluginAvailable(Vfs::Mode mode) return false; } + // Attempting to load the plugin is essential as it could have dependencies that + // can't be resolved and thus not be available after all. + if (!loader.load()) { + qCWarning(lcPlugin) << "Plugin failed to load:" << loader.errorString(); + return false; + } + return true; }