BlockTemplate: miner tx and root hash updating

This commit is contained in:
SChernykh 2021-06-16 23:44:05 +02:00
parent 93e689d601
commit 88959bd703
2 changed files with 54 additions and 19 deletions

View file

@ -73,6 +73,7 @@ struct BlockTemplate
uint64_t num_hashes;
Buffer hashes;
Buffer miner_tx_merkle_tree_branch;
uint8_t root_hash[HASH_SIZE];
Buffer hashingBlob;
@ -81,8 +82,9 @@ struct BlockTemplate
private:
void CalculateMinerTxHash(uint8_t* hash);
static void CalculateMerkleTreeHash(const uint8_t* hashes, size_t count, uint8_t* root_hash);
void CalculateHashingBlob();
void CalculateMerkleTreeHash();
void UpdateMinerTxHash();
void GenerateHashingBlob();
};