Stop miner trying to mine invalid block.

This commit is contained in:
blackjok3r
2019-02-04 10:06:54 +08:00
parent 2c88bb70b6
commit 2863dbc6d4
3 changed files with 26 additions and 3 deletions

View File

@@ -1811,8 +1811,6 @@ uint64_t komodo_notarypay(CMutableTransaction &txNew, std::vector<int8_t> &Notar
if ( staked_era == 0 )
return(0);
numSN = numStakedNotaries(staked_pubkeys,staked_era);
// resize coinbase vouts to number of notary nodes +1 for coinbase itself.
txNew.vout.resize(NotarisationNotaries.size()+1);
// Check the notarisation is valid, and extract notarised height.
uint64_t voutmask;
@@ -1833,6 +1831,9 @@ uint64_t komodo_notarypay(CMutableTransaction &txNew, std::vector<int8_t> &Notar
}
} else return(0);
// resize coinbase vouts to number of notary nodes +1 for coinbase itself.
txNew.vout.resize(NotarisationNotaries.size()+1);
// Calcualte the amount to pay.
AmountToPay = komodo_notarypayamount(notarizedheight,NotarisationNotaries.size());