Skip to content

Commit 8508778

Browse files
author
EhssanD
committed
Fixed empty PubKey
1 parent e6996b8 commit 8508778

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/miner/miner-util.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -379,6 +379,8 @@ void SetBlockPubkeyScript(CBlock& block, const CScript& scriptPubKeyIn)
379379
CMutableTransaction txCoinbase(*block.vtx[0]);
380380
// Set coinbase out address
381381
txCoinbase.vout[0].scriptPubKey = scriptPubKeyIn;
382+
//It should be added to the block
383+
block.vtx[0] = MakeTransactionRef(std::move(txCoinbase));
382384
// Generate merkle root hash
383385
block.hashMerkleRoot = BlockMerkleRoot(block);
384386
}

0 commit comments

Comments
 (0)