Hardening to avoid null-pointer crashes in the

presence of malformed class types.

<rdar://problem/13740646>

llvm-svn: 180645
This commit is contained in:
Sean Callanan 2013-04-26 22:54:19 +00:00
parent 969c5bd2d8
commit e5270598ba
1 changed files with 6 additions and 0 deletions

View File

@ -1016,6 +1016,9 @@ ClangExpressionDeclMap::FindExternalVisibleDecls (NameSearchContext &context,
{
QualType class_type = class_pointer_type->getPointeeType();
if (!class_type.getAsOpaquePtr())
return;
if (log)
{
ASTDumper ast_dumper(this_type->GetClangFullType());
@ -1144,6 +1147,9 @@ ClangExpressionDeclMap::FindExternalVisibleDecls (NameSearchContext &context,
QualType class_type = class_pointer_type->getPointeeType();
if (!class_type.getAsOpaquePtr())
return;
if (log)
{
ASTDumper ast_dumper(self_type->GetClangFullType());