Commit 4e35683e authored by Nikolai Kosjar's avatar Nikolai Kosjar
Browse files

C++: Fix null pointer dereference

Task-number: QTCREATORBUG-8698

Change-Id: If3181cb923ef7249945908c0610c16952262e881
Reviewed-by: default avatarhjk <>
Reviewed-by: default avatarErik Verbruggen <>
parent a7d2e3c7
......@@ -79,5 +79,11 @@ bool Name::Compare::operator()(const Name *name, const Name *other) const
const Identifier *id = name->identifier();
const Identifier *otherId = other->identifier();
if (id == 0)
return otherId != 0;
if (otherId == 0)
return false;
return std::strcmp(id->chars(), otherId->chars()) < 0;
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment