Skip to content

Commit e846964

Browse files
committed
Fix checkDummy() for null pointers
1 parent e5df0a1 commit e846964

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

clang/lib/AST/Interp/Interp.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -216,7 +216,7 @@ bool CheckLive(InterpState &S, CodePtr OpPC, const Pointer &Ptr,
216216
}
217217

218218
bool CheckDummy(InterpState &S, CodePtr OpPC, const Pointer &Ptr) {
219-
return !Ptr.isDummy();
219+
return !Ptr.isZero() && !Ptr.isDummy();
220220
}
221221

222222
bool CheckNull(InterpState &S, CodePtr OpPC, const Pointer &Ptr,

0 commit comments

Comments
 (0)