aboutsummaryrefslogtreecommitdiff
path: root/src/main.h
diff options
context:
space:
mode:
authorWladimir J. van der Laan <laanwj@gmail.com>2015-12-14 13:23:45 +0100
committerWladimir J. van der Laan <laanwj@gmail.com>2015-12-14 13:29:28 +0100
commit64360f13044125fbb3cdcbe2e5e8f2bfb82a8b27 (patch)
tree90bf76ee3d42ad447c5e5bd8c067e546fff3318b /src/main.h
parentdc511dcfd9eaa82a773d0a402b1500c3fd9113e0 (diff)
downloadbitcoin-64360f13044125fbb3cdcbe2e5e8f2bfb82a8b27.tar.xz
Make max tip age an option instead of chainparam
After discussion in #7164 I think this is better. Max tip age was introduced in #5987 to make it possible to run testnet-in-a-box. But associating this behavior with the testnet chain is wrong conceptually, as it is not needed in normal usage. Should aim to make testnet test the software as-is. Replace it with a (debug) option `-maxtipage`, which can be specified only in the specific case.
Diffstat (limited to 'src/main.h')
-rw-r--r--src/main.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/main.h b/src/main.h
index 19623f4d96..d06ad6caf3 100644
--- a/src/main.h
+++ b/src/main.h
@@ -89,6 +89,7 @@ static const unsigned int DATABASE_FLUSH_INTERVAL = 24 * 60 * 60;
static const unsigned int MAX_REJECT_MESSAGE_LENGTH = 111;
static const unsigned int DEFAULT_LIMITFREERELAY = 15;
static const bool DEFAULT_RELAYPRIORITY = true;
+static const int64_t DEFAULT_MAX_TIP_AGE = 24 * 60 * 60;
/** Default for -permitbaremultisig */
static const bool DEFAULT_PERMIT_BAREMULTISIG = true;
@@ -127,6 +128,7 @@ extern bool fCheckpointsEnabled;
extern size_t nCoinCacheUsage;
extern CFeeRate minRelayTxFee;
extern bool fAlerts;
+extern int64_t nMaxTipAge;
/** Best header we've seen so far (used for getheaders queries' starting points). */
extern CBlockIndex *pindexBestHeader;