mirror of
https://github.com/ElementsProject/elements.git
synced 2026-08-15 12:51:00 +02:00
Merge 7257e50dba into merged_master (Bitcoin PR bitcoin/bitcoin#20833)
This commit is contained in:
commit
8a669eccfb
16 changed files with 847 additions and 91 deletions
|
|
@ -288,7 +288,8 @@ CMutableTransaction TestChain100Setup::CreateValidMempoolTransaction(CTransactio
|
|||
int input_height,
|
||||
CKey input_signing_key,
|
||||
CScript output_destination,
|
||||
CAmount output_amount)
|
||||
CAmount output_amount,
|
||||
bool submit)
|
||||
{
|
||||
// Transaction we will submit to the mempool
|
||||
CMutableTransaction mempool_txn;
|
||||
|
|
@ -321,8 +322,8 @@ CMutableTransaction TestChain100Setup::CreateValidMempoolTransaction(CTransactio
|
|||
std::map<int, std::string> input_errors;
|
||||
assert(SignTransaction(mempool_txn, &keystore, input_coins, nHashType, input_errors));
|
||||
|
||||
// Add transaction to the mempool
|
||||
{
|
||||
// If submit=true, add transaction to the mempool.
|
||||
if (submit) {
|
||||
LOCK(cs_main);
|
||||
const MempoolAcceptResult result = AcceptToMemoryPool(::ChainstateActive(), *m_node.mempool.get(), MakeTransactionRef(mempool_txn), /* bypass_limits */ false);
|
||||
assert(result.m_result_type == MempoolAcceptResult::ResultType::VALID);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue