diff options
author | MarcoFalke <*~=`'#}+{/-|&$^_@721217.xyz> | 2023-07-06 14:28:15 +0200 |
---|---|---|
committer | MarcoFalke <*~=`'#}+{/-|&$^_@721217.xyz> | 2023-07-06 14:19:59 +0200 |
commit | fabed7eb796637c02e3677ebbe183d90b258ba69 (patch) | |
tree | d8fd4a70c0195e057a3eff428ec98acd1a12d7e4 | |
parent | bc4f6b13feb29146b7e10e86f93dc7f6fb6937f2 (diff) |
test: Restore unlimited timeout in IndexWaitSynced
The timeout was unlimited before, so just restore that value for now:
https://github.com/bitcoin/bitcoin/pull/27988#issuecomment-1619218007
-rw-r--r-- | src/test/util/index.cpp | 5 | ||||
-rw-r--r-- | src/test/util/index.h | 2 |
2 files changed, 2 insertions, 5 deletions
diff --git a/src/test/util/index.cpp b/src/test/util/index.cpp index 2bda7b1773..89bc35b731 100644 --- a/src/test/util/index.cpp +++ b/src/test/util/index.cpp @@ -5,14 +5,11 @@ #include <test/util/index.h> #include <index/base.h> -#include <util/check.h> #include <util/time.h> -void IndexWaitSynced(BaseIndex& index) +void IndexWaitSynced(const BaseIndex& index) { - const auto timeout{SteadyClock::now() + 120s}; while (!index.BlockUntilSyncedToCurrentChain()) { - Assert(timeout > SteadyClock::now()); UninterruptibleSleep(100ms); } } diff --git a/src/test/util/index.h b/src/test/util/index.h index 02030fd562..95309f6273 100644 --- a/src/test/util/index.h +++ b/src/test/util/index.h @@ -8,6 +8,6 @@ class BaseIndex; /** Block until the index is synced to the current chain */ -void IndexWaitSynced(BaseIndex& index); +void IndexWaitSynced(const BaseIndex& index); #endif // BITCOIN_TEST_UTIL_INDEX_H |