coinbase first

This commit is contained in:
Zane 2018-06-21 12:49:21 +08:00 committed by GitHub
parent ffd08b1afd
commit af63a875f5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -335,7 +335,7 @@ func handleTx(request []byte, bc *Blockchain) {
} }
cbTx := NewCoinbaseTX(miningAddress, "") cbTx := NewCoinbaseTX(miningAddress, "")
txs = append([]*block.Transaction{cbTx}, txs...) txs = append([]*Transaction{cbTx}, txs...)
newBlock := bc.MineBlock(txs) newBlock := bc.MineBlock(txs)
UTXOSet := UTXOSet{bc} UTXOSet := UTXOSet{bc}