Remove unnecessary const_cast
Signed-off-by: Julian Fleischer <julian@thirdhash.com>
This commit is contained in:
parent
ea022d9fd0
commit
5039e4b61b
1 changed files with 1 additions and 1 deletions
|
@ -4347,7 +4347,7 @@ bool CChainState::LoadGenesisBlock(const CChainParams& chainparams)
|
||||||
return true;
|
return true;
|
||||||
|
|
||||||
try {
|
try {
|
||||||
CBlock &block = const_cast<CBlock&>(chainparams.GenesisBlock());
|
const CBlock& block = chainparams.GenesisBlock();
|
||||||
CDiskBlockPos blockPos = SaveBlockToDisk(block, 0, chainparams, nullptr);
|
CDiskBlockPos blockPos = SaveBlockToDisk(block, 0, chainparams, nullptr);
|
||||||
if (blockPos.IsNull())
|
if (blockPos.IsNull())
|
||||||
return error("%s: writing genesis block to disk failed", __func__);
|
return error("%s: writing genesis block to disk failed", __func__);
|
||||||
|
|
Loading…
Reference in a new issue