address ub
All checks were successful
Blockstorage/repertory/pipeline/head This commit looks good
BlockStorage/repertory/pipeline/head This commit looks good

This commit is contained in:
2025-09-21 16:32:22 -05:00
parent 44bd4fce20
commit ac6a435c32

View File

@@ -61,7 +61,9 @@ auto kdf_config::generate_checksum() const -> std::uint64_t {
tmp.checksum = 0;
auto hash = utils::hash::create_hash_blake2b_64(tmp.to_header());
return *reinterpret_cast<std::uint64_t *>(hash.data());
std::uint64_t ret{};
std::memcpy(&ret, hash.data(), hash.size());
return ret;
}
auto kdf_config::from_header(data_cspan data, kdf_config &cfg,