Specify non-standard transaction error when it's dust
Signed-off-by: Anthony Fieroni <bvbfan@abv.bg>
This commit is contained in:
parent
72cbc491be
commit
ebeb2bd092
1 changed files with 6 additions and 2 deletions
|
@ -1034,8 +1034,12 @@ bool AcceptToMemoryPoolWorker(CTxMemPool& pool, CValidationState& state, const C
|
||||||
|
|
||||||
// Rather not work on nonstandard transactions (unless -testnet/-regtest)
|
// Rather not work on nonstandard transactions (unless -testnet/-regtest)
|
||||||
string reason;
|
string reason;
|
||||||
if (fRequireStandard && !IsStandardTx(tx, reason))
|
if (fRequireStandard && !IsStandardTx(tx, reason)) {
|
||||||
return state.DoS(0, false, REJECT_NONSTANDARD, reason);
|
if (reason == "dust")
|
||||||
|
return state.DoS(0, false, REJECT_DUST, reason);
|
||||||
|
else
|
||||||
|
return state.DoS(0, false, REJECT_NONSTANDARD, reason);
|
||||||
|
}
|
||||||
|
|
||||||
// Don't relay version 2 transactions until CSV is active, and we can be
|
// Don't relay version 2 transactions until CSV is active, and we can be
|
||||||
// sure that such transactions will be mined (unless we're on
|
// sure that such transactions will be mined (unless we're on
|
||||||
|
|
Loading…
Reference in a new issue