mirror of
https://github.com/ElementsProject/elements.git
synced 2026-08-16 13:01:19 +02:00
Only spin-wait MainchainRPCCheck on initial loading with warmup code
This commit is contained in:
parent
9d4097dca2
commit
ad43f9c60f
1 changed files with 2 additions and 1 deletions
|
|
@ -5161,7 +5161,8 @@ bool MainchainRPCCheck(const bool init)
|
|||
if (!error.isNull()) {
|
||||
// On the first call, it's possible to node is still in
|
||||
// warmup; in that case, just wait and retry.
|
||||
if (error["code"].get_int() == RPC_IN_WARMUP) {
|
||||
// If this is not the initial call, just report failure.
|
||||
if (init && error["code"].get_int() == RPC_IN_WARMUP) {
|
||||
MilliSleep(1000);
|
||||
continue;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue