fs: add Sha256HashGenerator, LZ4 decompressor

This commit is contained in:
Michael Scire 2021-12-14 08:51:27 -08:00 committed by SciresM
parent a2aec363d7
commit 01f7f567b9
11 changed files with 165 additions and 8 deletions

View file

@ -39,7 +39,7 @@ namespace ams::crypto::impl {
private:
State m_state;
public:
Sha1Impl() { /* ... */ }
Sha1Impl() { m_state.finalized = false; }
~Sha1Impl() {
static_assert(std::is_trivially_destructible<State>::value);
ClearMemory(std::addressof(m_state), sizeof(m_state));

View file

@ -44,7 +44,7 @@ namespace ams::crypto::impl {
private:
State m_state;
public:
Sha256Impl() { /* ... */ }
Sha256Impl() { m_state.finalized = false; }
~Sha256Impl() {
static_assert(std::is_trivially_destructible<State>::value);
ClearMemory(std::addressof(m_state), sizeof(m_state));