Jelajahi Sumber

BUG: GetDefiniton can return null

Bill Hoffman 24 tahun lalu
induk
melakukan
71b36a7164
1 mengubah file dengan 1 tambahan dan 1 penghapusan
  1. 1 1
      Source/cmElseCommand.cxx

+ 1 - 1
Source/cmElseCommand.cxx

@@ -118,7 +118,7 @@ bool cmElseCommand::InitialPass(std::vector<std::string> const& args)
     cmRegularExpression regEntry(args[2].c_str());
     
     // check for black line or comment
-    if (regEntry.find(def))
+    if (def && regEntry.find(def))
       {
       f = new cmIfFunctionBlocker();
       }