diff options
Diffstat (limited to 'src/webview/qtwebviewfunctions.cpp')
-rw-r--r-- | src/webview/qtwebviewfunctions.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/webview/qtwebviewfunctions.cpp b/src/webview/qtwebviewfunctions.cpp index 975bb17..01efbf6 100644 --- a/src/webview/qtwebviewfunctions.cpp +++ b/src/webview/qtwebviewfunctions.cpp @@ -61,9 +61,12 @@ QT_BEGIN_NAMESPACE void QtWebView::initialize() { if (QWebViewFactory::requiresExtraInitializationSteps()) { + // There might be plugins available, but their dependencies might not be met, + // so make sure we have a valid plugin before using it. + // Note: A warning will be printed later if we're unable to load the plugin. QWebViewPlugin *plugin = QWebViewFactory::getPlugin(); - Q_ASSERT(plugin); - plugin->prepare(); + if (plugin) + plugin->prepare(); } } |