Page MenuHomePhabricator

[backport#15713 3/5] Remove duplicate checks in SubmitMemoryPoolAndRelay
ClosedPublic

Authored by majcosta on Jun 6 2020, 22:24.

Details

Summary

IsCoinBase check is already performed early by
AcceptToMemoryPoolWorker
GetDepthInMainChain check is already perfomed by
BroadcastTransaction

To avoid deadlock we MUST keep lock order in
ResendWalletTransactions and CommitTransaction,
even if we lock cs_main again further.
in BroadcastTransaction. Lock order will need
to be clean at once in a future refactoring

https://github.com/bitcoin/bitcoin/pull/15713/commits/8753f5652b4710e66b50ce87788bf6f33619b75a


Depends on D6420

Partial backport of Core PR15713

Test Plan
ninja check-all

Event Timeline

majcosta requested review of this revision.Jun 6 2020, 22:24

[Bot Message]
One or more PR numbers were detected in the summary.
Links to those PRs have been inserted into the summary for reference.

deadalnix requested changes to this revision.Jun 6 2020, 22:35
deadalnix added a subscriber: deadalnix.

The patch doesn't seems to be the one in the description.

This revision now requires changes to proceed.Jun 6 2020, 22:35
majcosta requested review of this revision.Jun 6 2020, 22:53
majcosta edited the summary of this revision. (Show Details)

fat fingers, my bad

majcosta retitled this revision from [backport#15713] Remove duplicate checks in SubmitMemoryPoolAndRelay to [backport#15713 3/5] Remove duplicate checks in SubmitMemoryPoolAndRelay.Jun 6 2020, 22:56
This revision is now accepted and ready to land.Jun 6 2020, 23:17