aboutsummaryrefslogtreecommitdiff
path: root/src/interfaces/chain.cpp
diff options
context:
space:
mode:
authorJoão Barbosa <joao.paulo.barbosa@gmail.com>2019-03-27 17:00:06 +0000
committerJoão Barbosa <joao.paulo.barbosa@gmail.com>2019-03-31 11:37:28 +0100
commit57908a739ca377d60ef224ce0f565d4412a414f4 (patch)
tree985bb1d2e0bf3477e40faef44aa96d209d17b6e1 /src/interfaces/chain.cpp
parent0440481c6bf5683eff669c789bdf6a306d99adc5 (diff)
downloadbitcoin-57908a739ca377d60ef224ce0f565d4412a414f4.tar.xz
interfaces: Add Chain::requestMempoolTransactions
Diffstat (limited to 'src/interfaces/chain.cpp')
-rw-r--r--src/interfaces/chain.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/interfaces/chain.cpp b/src/interfaces/chain.cpp
index 0c765f2092..e409ced601 100644
--- a/src/interfaces/chain.cpp
+++ b/src/interfaces/chain.cpp
@@ -367,6 +367,13 @@ public:
{
return MakeUnique<RpcHandlerImpl>(command);
}
+ void requestMempoolTransactions(Notifications& notifications) override
+ {
+ LOCK2(::cs_main, ::mempool.cs);
+ for (const CTxMemPoolEntry& entry : ::mempool.mapTx) {
+ notifications.TransactionAddedToMempool(entry.GetSharedTx());
+ }
+ }
};
} // namespace