mastercoin-MSC / mastercore

mastercore info
mastercoin.org
MIT License
24 stars 11 forks source link

Sort pending wallet transactions before reaccepting #250

Closed dexX7 closed 9 years ago

dexX7 commented 9 years ago

During startup, when adding pending wallet transactions, which spend outputs of other pending wallet transactions, back to the memory pool, and when they are added out of order, it appears as if they are orphans with missing inputs.

Those transactions are then rejected and flagged as "conflicting" (= not in the memory pool, not in the block chain).

To prevent this, transactions are explicitly sorted.

m21 commented 9 years ago

Looks simple enough, but since this is Bitcoin Core specific - can you push it through upstream please? If it's an improvement they should like it and scrutinize it There may be intricate details we don't follow, nor should be following - instead concentrating on MP/Omni side. (Large wallets for instance, many TXs or many addresses or something else.)

dexX7 commented 9 years ago

Submitted, will update when denied or accepted.

Regarding large wallets: actually only the pending transactions are sorted, not every wallet transaction.

zathras-crypto commented 9 years ago

LGTM as discussed on the other thread mate :)

dexX7 commented 9 years ago

If merged into bitcoin:master, it's probably better to pull it from there. Review still ongoing, but no objections so far: https://github.com/bitcoin/bitcoin/pull/ 5511