aboutsummaryrefslogtreecommitdiff
path: root/src/txmempool.h
diff options
context:
space:
mode:
authorCarl Dong <contact@carldong.me>2021-10-28 14:13:04 -0400
committerCarl Dong <contact@carldong.me>2022-06-28 15:42:23 -0400
commitaa9141cd8185cb7ad532bc16feb9d302b05d9697 (patch)
tree18dad4b3fcdeb21bcfd473528e1764a78fffd2b9 /src/txmempool.h
parent51c7a41a5eb6fcb60333812c770d80227cf7b64d (diff)
downloadbitcoin-aa9141cd8185cb7ad532bc16feb9d302b05d9697.tar.xz
mempool: Pass in -mempoolexpiry instead of referencing gArgs
- Store the mempool expiry (-mempoolexpiry) in CTxMemPool as a std::chrono::seconds member. - Remove the requirement to explicitly specify a mempool expiry for LimitMempoolSize(...), just use the newly-introduced member. - Remove all now-unnecessary instances of: std::chrono::hours{gArgs.GetIntArg("-mempoolexpiry", DEFAULT_MEMPOOL_EXPIRY)}
Diffstat (limited to 'src/txmempool.h')
-rw-r--r--src/txmempool.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/txmempool.h b/src/txmempool.h
index 95fd56879f..0a91cf31c7 100644
--- a/src/txmempool.h
+++ b/src/txmempool.h
@@ -567,6 +567,7 @@ public:
using Options = kernel::MemPoolOptions;
const int64_t m_max_size_bytes;
+ const std::chrono::seconds m_expiry;
/** Create a new CTxMemPool.
* Sanity checks will be off by default for performance, because otherwise