More bulletproofing of DebugInfoDesc verify.
authorJim Laskey <jlaskey@mac.com>
Tue, 28 Mar 2006 01:30:18 +0000 (01:30 +0000)
committerJim Laskey <jlaskey@mac.com>
Tue, 28 Mar 2006 01:30:18 +0000 (01:30 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27203 91177308-0d34-0410-b5e6-96231b3b80d8

lib/CodeGen/MachineDebugInfo.cpp

index eb85f27a4750a885ef8d3ef81fe312e5df528fca..9876e652a830750a703c05364466175855c634b2 100644 (file)
@@ -1323,7 +1323,7 @@ GlobalVariable *DISerializer::Serialize(DebugInfoDesc *DD) {
 /// Verify - Return true if the GlobalVariable appears to be a valid
 /// serialization of a DebugInfoDesc.
 bool DIVerifier::Verify(Value *V) {
-  return Verify(getGlobalVariable(V));
+  return !V || Verify(getGlobalVariable(V));
 }
 bool DIVerifier::Verify(GlobalVariable *GV) {
   // NULLs are valid.