From 8a29109fe9cc4838185d17d94f5ee178c4b2abc1 Mon Sep 17 00:00:00 2001 From: Christian Stenger Date: Tue, 13 Jan 2015 08:24:47 +0100 Subject: [PATCH] ProjectExplorer: Fix possible accessing null pointer Change-Id: I285437f8eb21ce9f1a32d631a9c75d32d5ab2859 Reviewed-by: hjk --- src/plugins/projectexplorer/kitmodel.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/plugins/projectexplorer/kitmodel.cpp b/src/plugins/projectexplorer/kitmodel.cpp index 1cb8c239b7d..0c9a58e6583 100644 --- a/src/plugins/projectexplorer/kitmodel.cpp +++ b/src/plugins/projectexplorer/kitmodel.cpp @@ -166,6 +166,8 @@ KitManagerConfigWidget *KitModel::widget(const QModelIndex &index) if (!index.isValid()) return 0; KitNode *node = static_cast(index.internalPointer()); + if (node == m_autoRoot || node == m_manualRoot) + return 0; return node->widget; }