summaryrefslogtreecommitdiffstats
path: root/Source/CPack/cmCPackFreeBSDGenerator.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2019-01-15 18:21:14 (GMT)
committerKitware Robot <kwrobot@kitware.com>2019-01-15 18:21:21 (GMT)
commit67422bf579e5c274794f131f008bec4ec1e7d4b9 (patch)
treebfaa86dd5586cda12ff3833c2ebc0018e71bbfde /Source/CPack/cmCPackFreeBSDGenerator.cxx
parentd7835e4d0e6858eeff12c6e8d09a42db6acad4bd (diff)
parent414aa6c81ec62ab2f728fab31aa189ce674484a4 (diff)
downloadCMake-67422bf579e5c274794f131f008bec4ec1e7d4b9.zip
CMake-67422bf579e5c274794f131f008bec4ec1e7d4b9.tar.gz
CMake-67422bf579e5c274794f131f008bec4ec1e7d4b9.tar.bz2
Merge topic 'simplify-boolean-expr'
414aa6c81e clang-tidy: Simplify boolean expressions Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !2740
Diffstat (limited to 'Source/CPack/cmCPackFreeBSDGenerator.cxx')
-rw-r--r--Source/CPack/cmCPackFreeBSDGenerator.cxx9
1 files changed, 2 insertions, 7 deletions
diff --git a/Source/CPack/cmCPackFreeBSDGenerator.cxx b/Source/CPack/cmCPackFreeBSDGenerator.cxx
index 2fcd1a8..1e6b118 100644
--- a/Source/CPack/cmCPackFreeBSDGenerator.cxx
+++ b/Source/CPack/cmCPackFreeBSDGenerator.cxx
@@ -257,13 +257,8 @@ void cmCPackFreeBSDGenerator::write_manifest_fields(
static bool ignore_file(const std::string& filename)
{
struct stat statbuf;
-
- if (!((stat(filename.c_str(), &statbuf) >= 0) &&
- ((statbuf.st_mode & S_IFMT) == S_IFREG))) {
- return true;
- }
- // May be other reasons to return false
- return false;
+ return stat(filename.c_str(), &statbuf) < 0 ||
+ (statbuf.st_mode & S_IFMT) != S_IFREG;
}
// Write the given list of @p files to the manifest stream @p s,