diff options
author | Maximilian Goldstein <max.goldstein@qt.io> | 2021-02-03 12:06:33 +0100 |
---|---|---|
committer | Ulf Hermann <ulf.hermann@qt.io> | 2021-02-19 12:14:00 +0000 |
commit | bf8888971732dbd0012eadc53cddada59bb17b2e (patch) | |
tree | 75d1fb001632a78aa7ef2bd05fd66c838743cbaa /tools | |
parent | 39a214773d554a1a03b49a7ab08b0a60a59c8279 (diff) |
qmllint: Fix segmentation fault
Change-Id: Ie04ad4221b25628687c2575facf90488b83d21bf
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
(cherry picked from commit 5fb34b67b810ca284c216009925f4f38220c4510)
Diffstat (limited to 'tools')
-rw-r--r-- | tools/qmllint/checkidentifiers.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/qmllint/checkidentifiers.cpp b/tools/qmllint/checkidentifiers.cpp index e78ebdae90..b41b68b719 100644 --- a/tools/qmllint/checkidentifiers.cpp +++ b/tools/qmllint/checkidentifiers.cpp @@ -252,7 +252,7 @@ bool CheckIdentifiers::checkMemberAccess(const QVector<FieldMember> &members, if (access.m_name.front().isUpper() && scope->scopeType() == QQmlJSScope::QMLScope) { // may be an attached type const auto it = m_types.find(access.m_name); - if (it != m_types.end() && !(*it)->attachedTypeName().isEmpty()) { + if (it != m_types.end() && *it && !(*it)->attachedTypeName().isEmpty()) { if (const auto attached = (*it)->attachedType()) { scope = attached; continue; |