ChainstateManager::ProcessTransaction

Try to add a transaction to the memory pool.

Synopsis

Declared in <validation.h>

[[nodiscard, requires_capability(0x7ff37ba95658), requires_capability(0x7ff375ddbfe8), requires_capability(0x7ff37e1a58b8), requires_capability(0x7ff375a97728)]]
MempoolAcceptResult
ProcessTransaction(
    CTransactionRef const& tx,
    bool test_accept = false);

Return Value

a MempoolAcceptResult indicating whether the transaction was accepted or rejected.

NOTE

The return value should not be discarded.

Parameters

NameDescription
tx [in]The transaction to submit for mempool acceptance.
test_accept [in]When true, run validation checks but don't submit to mempool.