summaryrefslogtreecommitdiffstats
path: root/Source/cmake.cxx
diff options
context:
space:
mode:
authorscivision <scivision@users.noreply.github.com>2023-09-18 03:01:40 (GMT)
committerBrad King <brad.king@kitware.com>2023-09-18 20:35:10 (GMT)
commitf5ff17fcf29170541805e7fc7f4a74252fe39b10 (patch)
treeeef38695bb40d69488305fd618a85afb424a7e02 /Source/cmake.cxx
parentd007eb70468437cb7a1f30d160f3b97263cbc087 (diff)
downloadCMake-f5ff17fcf29170541805e7fc7f4a74252fe39b10.zip
CMake-f5ff17fcf29170541805e7fc7f4a74252fe39b10.tar.gz
CMake-f5ff17fcf29170541805e7fc7f4a74252fe39b10.tar.bz2
Source: Remove redundant FileIsSymlink checks
Replace `FileExists || FileIsSymlink` with `PathExists`. The latter does not resolve symlinks, so this is OK for use with broken symlinks, files, and directories.
Diffstat (limited to 'Source/cmake.cxx')
-rw-r--r--Source/cmake.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/Source/cmake.cxx b/Source/cmake.cxx
index 1d8a847..1fa0cbe 100644
--- a/Source/cmake.cxx
+++ b/Source/cmake.cxx
@@ -3264,7 +3264,7 @@ int cmake::CheckBuildSystem()
// If any byproduct of makefile generation is missing we must re-run.
cmList products{ mf.GetDefinition("CMAKE_MAKEFILE_PRODUCTS") };
for (auto const& p : products) {
- if (!(cmSystemTools::FileExists(p) || cmSystemTools::FileIsSymlink(p))) {
+ if (!cmSystemTools::PathExists(p)) {
if (verbose) {
cmSystemTools::Stdout(
cmStrCat("Re-run cmake, missing byproduct: ", p, '\n'));