From 672c38840765834d58c66e1b1741f6b03b1b4031 Mon Sep 17 00:00:00 2001 From: nowrep Date: Fri, 12 Apr 2013 17:49:22 +0200 Subject: [PATCH] [Plugins] Print error message when failed to load plugin. Prints QPluginLoader's error message to the stderr. --- src/lib/plugins/plugins.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/lib/plugins/plugins.cpp b/src/lib/plugins/plugins.cpp index d11331c67..ac1b34df1 100644 --- a/src/lib/plugins/plugins.cpp +++ b/src/lib/plugins/plugins.cpp @@ -24,6 +24,7 @@ #include #include #include +#include Plugins::Plugins(QObject* parent) : QObject(parent) @@ -132,6 +133,7 @@ void Plugins::loadPlugins() QPluginLoader* loader = new QPluginLoader(fullPath); PluginInterface* iPlugin = qobject_cast(loader->instance()); if (!iPlugin) { + qWarning() << "Plugins::loadPlugins" << loader->errorString(); continue; } @@ -189,6 +191,7 @@ void Plugins::loadAvailablePlugins() PluginInterface* iPlugin = qobject_cast(loader->instance()); if (!iPlugin) { + qWarning() << "Plugins::loadAvailablePlugins" << loader->errorString(); continue; }