forked from qt-creator/qt-creator
CMake: Fix potential nullptr access
Change-Id: I08bcbde9702bb9bea5fe4f24247eb3856e79f339 Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
This commit is contained in:
committed by
Tim Jenssen
parent
c4ff03d8b5
commit
9801472d33
@@ -177,6 +177,8 @@ QModelIndex CMakeToolItemModel::addCMakeTool(const QString &name, const FileName
|
|||||||
|
|
||||||
void CMakeToolItemModel::addCMakeTool(const CMakeTool *item, bool changed)
|
void CMakeToolItemModel::addCMakeTool(const CMakeTool *item, bool changed)
|
||||||
{
|
{
|
||||||
|
QTC_ASSERT(item, return);
|
||||||
|
|
||||||
if (cmakeToolItem(item->id()))
|
if (cmakeToolItem(item->id()))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user