Explorar el Código

Merge topic 'find_package-check-dir' into release-3.19

0356b81525 find_package: Fix regression in searching root prefix

Acked-by: Kitware Robot <[email protected]>
Merge-request: !5396
Brad King hace 5 años
padre
commit
bb4e2f3f9a
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      Source/cmFindPackageCommand.cxx

+ 1 - 1
Source/cmFindPackageCommand.cxx

@@ -1984,7 +1984,7 @@ cmFileListGeneratorBase* cmFileListGeneratorBase::SetNext(
 bool cmFileListGeneratorBase::Consider(std::string const& fullPath,
                                        cmFileList& listing)
 {
-  if (!cmSystemTools::FileIsDirectory(fullPath)) {
+  if (!fullPath.empty() && !cmSystemTools::FileIsDirectory(fullPath)) {
     return false;
   }
   if (this->Next) {