From da8d304960d0e1368e5a08a4107537cab6bea52f Mon Sep 17 00:00:00 2001 From: CAnon Date: Tue, 7 Jun 2022 23:16:25 +0800 Subject: refactor: Move DEFAULT_ANCESTOR_LIMIT to policy/policy.h --- src/policy/policy.h | 2 ++ src/validation.h | 3 +-- 2 files changed, 3 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/policy/policy.h b/src/policy/policy.h index 94f9623b8a..0f199f928f 100644 --- a/src/policy/policy.h +++ b/src/policy/policy.h @@ -57,6 +57,8 @@ static const unsigned int MAX_STANDARD_SCRIPTSIG_SIZE = 1650; static const unsigned int DUST_RELAY_TX_FEE = 3000; /** Default for -minrelaytxfee, minimum relay fee for transactions */ static const unsigned int DEFAULT_MIN_RELAY_TX_FEE = 1000; +/** Default for -limitancestorcount, max number of in-mempool ancestors */ +static constexpr unsigned int DEFAULT_ANCESTOR_LIMIT{25}; /** * Standard script verification flags that standard transactions will comply * with. However scripts violating these flags may still be present in valid diff --git a/src/validation.h b/src/validation.h index 70b6c072e6..676997aa46 100644 --- a/src/validation.h +++ b/src/validation.h @@ -21,6 +21,7 @@ #include #include #include +#include #include