diff options
author | fanquake <fanquake@gmail.com> | 2018-07-11 15:14:29 +0800 |
---|---|---|
committer | fanquake <fanquake@gmail.com> | 2018-07-25 07:30:28 +0800 |
commit | 3828a797115a879705085ccbb373e607def61234 (patch) | |
tree | 528cd0f9f194b5abc47a875f0aae5ba7148e8eb6 | |
parent | fa6e841e89d164850dcfb6efe5b03992594c1ca3 (diff) |
scripted-diff: prefer MAC_OSX over __APPLE__
-BEGIN VERIFY SCRIPT-
sed -i 's/__APPLE__/MAC_OSX/g' src/compat/byteswap.h src/util.cpp
-END VERIFY SCRIPT-
-rw-r--r-- | src/compat/byteswap.h | 4 | ||||
-rw-r--r-- | src/util.cpp | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/compat/byteswap.h b/src/compat/byteswap.h index c331af2b5e..bfb80bd632 100644 --- a/src/compat/byteswap.h +++ b/src/compat/byteswap.h @@ -15,7 +15,7 @@ #include <byteswap.h> #endif -#if defined(__APPLE__) +#if defined(MAC_OSX) #if !defined(bswap_16) @@ -61,6 +61,6 @@ inline uint64_t bswap_64(uint64_t x) } #endif // HAVE_DECL_BSWAP64 == 0 -#endif // defined(__APPLE__) +#endif // defined(MAC_OSX) #endif // BITCOIN_COMPAT_BYTESWAP_H diff --git a/src/util.cpp b/src/util.cpp index 8df23dd08f..2f81f50a71 100644 --- a/src/util.cpp +++ b/src/util.cpp @@ -1021,7 +1021,7 @@ bool FileCommit(FILE *file) LogPrintf("%s: fdatasync failed: %d\n", __func__, errno); return false; } - #elif defined(__APPLE__) && defined(F_FULLFSYNC) + #elif defined(MAC_OSX) && defined(F_FULLFSYNC) if (fcntl(fileno(file), F_FULLFSYNC, 0) == -1) { // Manpage says "value other than -1" is returned on success LogPrintf("%s: fcntl F_FULLFSYNC failed: %d\n", __func__, errno); return false; |