Line data Source code
1 : // Copyright (c) 2009-2010 Satoshi Nakamoto 2 : // Copyright (c) 2009-2018 The Bitcoin Core developers 3 : // Distributed under the MIT software license, see the accompanying 4 : // file COPYING or http://www.opensource.org/licenses/mit-license.php. 5 : 6 : #include <shutdown.h> 7 : 8 : #include <atomic> 9 : 10 : static std::atomic<bool> fRequestShutdown(false); 11 : 12 492 : void StartShutdown() 13 : { 14 492 : fRequestShutdown = true; 15 492 : } 16 0 : void AbortShutdown() 17 : { 18 0 : fRequestShutdown = false; 19 0 : } 20 423163 : bool ShutdownRequested() 21 : { 22 423163 : return fRequestShutdown; 23 : }