Skip to content

Commit

Permalink
consensus: modify the block hasher for scrypt
Browse files Browse the repository at this point in the history
  • Loading branch information
barrystyle committed Oct 21, 2023
1 parent 5b4f4d1 commit 5078657
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions src/primitives/block.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,13 @@

uint256 CBlockHeader::GetHash() const
{
CBlockHeader tmp(*this);
tmp.nFlags = 0;
return SerializeHash(tmp);
if (nVersion > 7) {
CBlockHeader tmp(*this);
tmp.nFlags = 0;
return SerializeHash(tmp);
}

return GetPoWHash();
}

uint256 CBlockHeader::GetPoWHash() const
Expand Down

0 comments on commit 5078657

Please sign in to comment.