Skip to content

Commit 95c73da

Browse files
Merge pull request #9604 from adrian-prantl/131871602
Add missing nullptr check
2 parents fec1308 + 1b31982 commit 95c73da

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

lldb/source/Plugins/TypeSystem/Swift/TypeSystemSwiftTypeRef.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3193,6 +3193,8 @@ lldb::Encoding TypeSystemSwiftTypeRef::GetEncoding(opaque_compiler_type_t type,
31933193
using namespace swift::Demangle;
31943194
Demangler dem;
31953195
auto *node = DemangleCanonicalType(dem, type);
3196+
if (!node)
3197+
return lldb::eEncodingInvalid;
31963198
auto kind = node->getKind();
31973199

31983200
if (kind == Node::Kind::BuiltinTypeName) {

0 commit comments

Comments
 (0)