diff options
Diffstat (limited to 'src/bitcoind.cpp')
-rw-r--r-- | src/bitcoind.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/bitcoind.cpp b/src/bitcoind.cpp index 374678310c..f3844e9d47 100644 --- a/src/bitcoind.cpp +++ b/src/bitcoind.cpp @@ -159,7 +159,12 @@ bool AppInit(int argc, char* argv[]) return false; #endif // HAVE_DECL_DAEMON } - + // Lock data directory after daemonization + if (!AppInitLockDataDirectory()) + { + // If locking the data directory failed, exit immediately + exit(EXIT_FAILURE); + } fRet = AppInitMain(threadGroup, scheduler); } catch (const std::exception& e) { |