diff options
author | Wladimir J. van der Laan <laanwj@gmail.com> | 2018-04-11 11:41:41 +0200 |
---|---|---|
committer | Wladimir J. van der Laan <laanwj@gmail.com> | 2018-04-11 11:43:23 +0200 |
commit | 807d2ac1867cc0b8c3ada4203b61fa29f6035318 (patch) | |
tree | 811a893a2b44b5bb7c5e8cd65104eeece65bbbcd | |
parent | 9b3370d1c612318f51ee911bc84d6f9966a54c6f (diff) | |
parent | 12e7c558afb1ddd127229029ef0770184d786927 (diff) | |
download | bitcoin-807d2ac1867cc0b8c3ada4203b61fa29f6035318.tar.xz |
Merge #12941: [Trivial] Ignore macOS daemon() depracation warning
12e7c55 Ignore macOS daemon() depracation warning (Jonas Schnelli)
Pull request description:
`daemon()` is deprecated on OSX since 10.5 (should migrate to `posix_spawn()`). There are no signs `daemon()` will get removed by Apple.
Tree-SHA512: d5bcdc5d6b507576e0358906a73f9c766f2072f4a9aef6bdc559e10dbec95337ffa50a1ccb60f7197591e2e74f87c74c13387de880aaedc6dbf3796253f69561
-rw-r--r-- | src/bitcoind.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/bitcoind.cpp b/src/bitcoind.cpp index 4aa811b86b..83d9719df2 100644 --- a/src/bitcoind.cpp +++ b/src/bitcoind.cpp @@ -139,6 +139,10 @@ bool AppInit(int argc, char* argv[]) if (gArgs.GetBoolArg("-daemon", false)) { #if HAVE_DECL_DAEMON +#if defined(MAC_OSX) +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wdeprecated-declarations" +#endif fprintf(stdout, "Bitcoin server starting\n"); // Daemonize @@ -146,6 +150,9 @@ bool AppInit(int argc, char* argv[]) fprintf(stderr, "Error: daemon() failed: %s\n", strerror(errno)); return false; } +#if defined(MAC_OSX) +#pragma GCC diagnostic pop +#endif #else fprintf(stderr, "Error: -daemon is not supported on this operating system\n"); return false; |