forked from qt-creator/qt-creator
C++: Fix crash in LookupContext::lookupType()
Task-number: QTCREATORBUG-10019 Change-Id: I7970c2f1ea3044e11250b8dbaf9b29ba3e7f34ef Reviewed-by: hjk <hjk121@nokiamail.com> Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
This commit is contained in:
@@ -308,7 +308,7 @@ ClassOrNamespace *LookupContext::lookupType(const Name *name, Scope *scope,
|
||||
ClassOrNamespace* enclosingTemplateInstantiation,
|
||||
QSet<const Declaration *> typedefsBeingResolved) const
|
||||
{
|
||||
if (! scope) {
|
||||
if (! scope || ! name) {
|
||||
return 0;
|
||||
} else if (Block *block = scope->asBlock()) {
|
||||
for (unsigned i = 0; i < block->memberCount(); ++i) {
|
||||
|
Reference in New Issue
Block a user