From 0bb17b08d30872dc8561af9c8cde5fca580df516 Mon Sep 17 00:00:00 2001 From: malte_langkabel Date: Fri, 7 Oct 2016 10:41:28 +0200 Subject: [PATCH] logic: fixed refresh crash reported in issue #220 --- src/lib/Application.cpp | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/src/lib/Application.cpp b/src/lib/Application.cpp index e842e4b0..715ac772 100644 --- a/src/lib/Application.cpp +++ b/src/lib/Application.cpp @@ -188,13 +188,16 @@ void Application::createAndLoadProject(const FilePath& projectSettingsFilePath) void Application::refreshProject(bool force) { - bool indexing = m_project->refresh(force); - if (indexing) + if (m_project) { - m_storageCache->clear(); - if (m_hasGUI) + bool indexing = m_project->refresh(force); + if (indexing) { - m_componentManager->refreshViews(); + m_storageCache->clear(); + if (m_hasGUI) + { + m_componentManager->refreshViews(); + } } } }