diff options
author | Wladimir J. van der Laan <laanwj@gmail.com> | 2014-08-15 10:53:23 +0200 |
---|---|---|
committer | Wladimir J. van der Laan <laanwj@gmail.com> | 2014-08-15 14:09:33 +0200 |
commit | 984ff68c679e9a40e14e791c6363c6136639a686 (patch) | |
tree | 71f67460c82fb19e45cde56c6654bbb148a25f38 /src/txmempool.h | |
parent | 6b099402b40dcf9fc716be29c85e7e1865b28e92 (diff) | |
parent | 6f2c26a457d279138d23d0f321edf55cd6b1f72f (diff) | |
download | bitcoin-984ff68c679e9a40e14e791c6363c6136639a686.tar.xz |
Merge pull request #4638
6f2c26a Closely track mempool byte total. Add "getmempoolinfo" RPC. (Jeff Garzik)
Diffstat (limited to 'src/txmempool.h')
-rw-r--r-- | src/txmempool.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/txmempool.h b/src/txmempool.h index 41b2c52f39..2577397bce 100644 --- a/src/txmempool.h +++ b/src/txmempool.h @@ -68,6 +68,7 @@ private: CMinerPolicyEstimator* minerPolicyEstimator; CFeeRate minRelayFee; // Passed to constructor to avoid dependency on main + uint64_t totalTxSize; // sum of all mempool tx' byte sizes public: mutable CCriticalSection cs; @@ -108,6 +109,11 @@ public: LOCK(cs); return mapTx.size(); } + uint64_t GetTotalTxSize() + { + LOCK(cs); + return totalTxSize; + } bool exists(uint256 hash) { |