From 9e73d0dac0774955348a5164087363c5b33927b8 Mon Sep 17 00:00:00 2001 From: Aqua-sama Date: Fri, 18 Jan 2019 16:56:54 +0100 Subject: Add tools/report-clang-tidy.sh - Fix various clang-tidy warnings - Fix use-after-free crash when deleting profiles --- src/session/session.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/session/session.cpp') diff --git a/src/session/session.cpp b/src/session/session.cpp index 51575bf..67cea70 100644 --- a/src/session/session.cpp +++ b/src/session/session.cpp @@ -120,7 +120,7 @@ void Session::restoreView(WebView *view, const QJsonObject &data) Q_CHECK_PTR(profileManager); auto *profile = profileManager->profile(data["profile"].toString()); - if(profile) + if(profile != nullptr) view->setProfile(profile); auto url = data.value("url"); -- cgit v1.2.1