mirror of
https://github.com/ElementsProject/elements.git
synced 2026-08-18 13:17:55 +02:00
rpc: factor out RpcInterruptionPoint from dumptxoutset
This commit is contained in:
parent
b5c423c48e
commit
fa7fc5a8e0
3 changed files with 11 additions and 5 deletions
|
|
@ -11,9 +11,9 @@
|
|||
#include <util/strencodings.h>
|
||||
#include <util/system.h>
|
||||
|
||||
#include <boost/signals2/signal.hpp>
|
||||
#include <boost/algorithm/string/classification.hpp>
|
||||
#include <boost/algorithm/string/split.hpp>
|
||||
#include <boost/signals2/signal.hpp>
|
||||
|
||||
#include <memory> // for unique_ptr
|
||||
#include <unordered_map>
|
||||
|
|
@ -309,6 +309,11 @@ bool IsRPCRunning()
|
|||
return g_rpc_running;
|
||||
}
|
||||
|
||||
void RpcInterruptionPoint()
|
||||
{
|
||||
if (!IsRPCRunning()) throw JSONRPCError(RPC_CLIENT_NOT_CONNECTED, "Shutting down");
|
||||
}
|
||||
|
||||
void SetRPCWarmupStatus(const std::string& newStatus)
|
||||
{
|
||||
LOCK(cs_rpcWarmup);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue