1
mirror of https://invent.kde.org/network/falkon.git synced 2024-11-11 09:32:12 +01:00

WebScrollBarManager: Guard against ScrollBarData being deleted

This commit is contained in:
David Rosca 2017-01-26 20:45:38 +01:00
parent fcc356e4df
commit f9a0d202de

View File

@ -142,7 +142,7 @@ void WebScrollBarManager::addWebView(WebView *view)
QPointer<WebView> p(view); QPointer<WebView> p(view);
view->page()->runJavaScript(source, WebPage::SafeJsWorld, [=](const QVariant &res) { view->page()->runJavaScript(source, WebPage::SafeJsWorld, [=](const QVariant &res) {
if (!p) { if (!p || !m_scrollbars.contains(view)) {
return; return;
} }
const QVariantMap map = res.toMap(); const QVariantMap map = res.toMap();