Skip to content

Commit 1db5ad0

Browse files
committed
Serialization: Fix null dereference in witness deserialization
Fix null dereference in deserialization logic for conformances. If deserializing the witness itself failed, don't try to get its actor isolation. rdar://162158608
1 parent a956308 commit 1db5ad0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/Serialization/Deserialization.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9158,7 +9158,7 @@ void ModuleFile::finishNormalConformance(NormalProtocolConformance *conformance,
91589158

91599159
// Determine whether we need to enter the actor isolation of the witness.
91609160
std::optional<ActorIsolation> enterIsolation;
9161-
if (*rawIDIter++) {
9161+
if (*rawIDIter++ && witness) {
91629162
enterIsolation = getActorIsolation(witness);
91639163
}
91649164

0 commit comments

Comments
 (0)