diff options
author | Brad King <brad.king@kitware.com> | 2016-06-03 14:45:40 (GMT) |
---|---|---|
committer | CMake Topic Stage <kwrobot@kitware.com> | 2016-06-03 14:45:40 (GMT) |
commit | 811831a958c91404193cc0a35d2d90f8351eb51c (patch) | |
tree | 589c888e14f727eb48adb6f0fa7f3f83cace3f65 /Source/cmDependsFortran.cxx | |
parent | 8b289db739c8d0a288e532c560b6dbcf4bd67c30 (diff) | |
parent | 7f6b8d3399dd841b0d29bf74d2b31021738c4ef8 (diff) | |
download | CMake-811831a958c91404193cc0a35d2d90f8351eb51c.zip CMake-811831a958c91404193cc0a35d2d90f8351eb51c.tar.gz CMake-811831a958c91404193cc0a35d2d90f8351eb51c.tar.bz2 |
Merge topic 'simplify-boolean-expressions'
7f6b8d33 Simplify boolean expressions
Diffstat (limited to 'Source/cmDependsFortran.cxx')
-rw-r--r-- | Source/cmDependsFortran.cxx | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/Source/cmDependsFortran.cxx b/Source/cmDependsFortran.cxx index 38e319d..a20fb98 100644 --- a/Source/cmDependsFortran.cxx +++ b/Source/cmDependsFortran.cxx @@ -654,10 +654,9 @@ bool cmDependsFortran::ModulesDiffer(const char* modFile, // but also do not include a date so we can fall through to // compare them without skipping any prefix. unsigned char hdr[2]; - bool okay = - finModFile.read(reinterpret_cast<char*>(hdr), 2) ? true : false; + bool okay = !finModFile.read(reinterpret_cast<char*>(hdr), 2).fail(); finModFile.seekg(0); - if (!(okay && hdr[0] == 0x1f && hdr[1] == 0x8b)) { + if (!okay || hdr[0] != 0x1f || hdr[1] != 0x8b) { const char seq[1] = { '\n' }; const int seqlen = 1; |