mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-13 07:28:59 +01:00
Return EXIT_FAILURE on post-init fatal errors
It seems odd to return `EXIT_SUCCESS` when the node aborted execution due a fatal internal error or any post-init problem that triggers an unrequested shutdown. e.g. blocks or coins db I/O errors, disconnect block failure, failure during thread import (external blocks loading process error), among others. Co-authored-by: Ryan Ofsky <ryan@ofsky.org>
This commit is contained in:
@@ -38,7 +38,7 @@ void InitParameterInteraction(ArgsManager& args);
|
||||
* @note This can be done before daemonization. Do not call Shutdown() if this function fails.
|
||||
* @pre Parameters should be parsed and config file should be read.
|
||||
*/
|
||||
bool AppInitBasicSetup(const ArgsManager& args);
|
||||
bool AppInitBasicSetup(const ArgsManager& args, std::atomic<int>& exit_status);
|
||||
/**
|
||||
* Initialization: parameter interaction.
|
||||
* @note This can be done before daemonization. Do not call Shutdown() if this function fails.
|
||||
|
||||
Reference in New Issue
Block a user