mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-12-13 14:14:00 +01:00
Use HashWriter where possible
This commit is contained in:
@@ -86,9 +86,9 @@ uint256 SHA256Uint256(const uint256& input)
|
||||
return result;
|
||||
}
|
||||
|
||||
CHashWriter TaggedHash(const std::string& tag)
|
||||
HashWriter TaggedHash(const std::string& tag)
|
||||
{
|
||||
CHashWriter writer(SER_GETHASH, 0);
|
||||
HashWriter writer{};
|
||||
uint256 taghash;
|
||||
CSHA256().Write((const unsigned char*)tag.data(), tag.size()).Finalize(taghash.begin());
|
||||
writer << taghash << taghash;
|
||||
|
||||
Reference in New Issue
Block a user