mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-06-02 17:24:58 +02:00
move-only: Add txorphanage module
This module captures orphan tracking code for tx relay. Can be reviewed with --color-moved=dimmed-zebra
This commit is contained in:
@@ -14,6 +14,7 @@
|
||||
#include <script/signingprovider.h>
|
||||
#include <script/standard.h>
|
||||
#include <serialize.h>
|
||||
#include <txorphanage.h>
|
||||
#include <util/memory.h>
|
||||
#include <util/string.h>
|
||||
#include <util/system.h>
|
||||
@@ -45,15 +46,6 @@ struct CConnmanTest : public CConnman {
|
||||
|
||||
// Tests these internal-to-net_processing.cpp methods:
|
||||
extern bool AddOrphanTx(const CTransactionRef& tx, NodeId peer);
|
||||
extern void EraseOrphansFor(NodeId peer);
|
||||
extern unsigned int LimitOrphanTxSize(unsigned int nMaxOrphans);
|
||||
|
||||
struct COrphanTx {
|
||||
CTransactionRef tx;
|
||||
NodeId fromPeer;
|
||||
int64_t nTimeExpire;
|
||||
};
|
||||
extern std::map<uint256, COrphanTx> mapOrphanTransactions GUARDED_BY(g_cs_orphans);
|
||||
|
||||
static CService ip(uint32_t i)
|
||||
{
|
||||
|
||||
@@ -18,6 +18,7 @@
|
||||
#include <test/util/net.h>
|
||||
#include <test/util/setup_common.h>
|
||||
#include <test/util/validation.h>
|
||||
#include <txorphanage.h>
|
||||
#include <util/memory.h>
|
||||
#include <validationinterface.h>
|
||||
#include <version.h>
|
||||
|
||||
@@ -13,6 +13,7 @@
|
||||
#include <test/util/net.h>
|
||||
#include <test/util/setup_common.h>
|
||||
#include <test/util/validation.h>
|
||||
#include <txorphanage.h>
|
||||
#include <util/memory.h>
|
||||
#include <validation.h>
|
||||
#include <validationinterface.h>
|
||||
|
||||
Reference in New Issue
Block a user