Changeset View
Changeset View
Standalone View
Standalone View
src/rpc/rawtransaction.cpp
Show First 20 Lines • Show All 988 Lines • ▼ Show 20 Lines | return RPCHelpMan{ | ||||
NodeContext &node = EnsureAnyNodeContext(request.context); | NodeContext &node = EnsureAnyNodeContext(request.context); | ||||
CTxMemPool &mempool = EnsureMemPool(node); | CTxMemPool &mempool = EnsureMemPool(node); | ||||
ChainstateManager &chainman = EnsureChainman(node); | ChainstateManager &chainman = EnsureChainman(node); | ||||
Chainstate &chainstate = chainman.ActiveChainstate(); | Chainstate &chainstate = chainman.ActiveChainstate(); | ||||
const PackageMempoolAcceptResult package_result = [&] { | const PackageMempoolAcceptResult package_result = [&] { | ||||
LOCK(::cs_main); | LOCK(::cs_main); | ||||
if (txns.size() > 1) { | if (txns.size() > 1) { | ||||
return ProcessNewPackage(config, chainstate, mempool, txns, | return ProcessNewPackage(chainstate, mempool, txns, | ||||
/* test_accept */ true); | /* test_accept */ true); | ||||
} | } | ||||
return PackageMempoolAcceptResult( | return PackageMempoolAcceptResult( | ||||
txns[0]->GetId(), | txns[0]->GetId(), | ||||
chainman.ProcessTransaction(txns[0], | chainman.ProcessTransaction(txns[0], | ||||
/* test_accept*/ true)); | /* test_accept*/ true)); | ||||
}(); | }(); | ||||
▲ Show 20 Lines • Show All 1,113 Lines • Show Last 20 Lines |