From 91ef9bb92c7280613f8573cc9eef13ac6822e2f8 Mon Sep 17 00:00:00 2001 From: Michael Scire Date: Sat, 16 Apr 2022 12:28:40 -0700 Subject: [PATCH] fs: fix null check in AesXtsStorageExternal --- .../source/fssystem/fssystem_aes_xts_storage_external.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libstratosphere/source/fssystem/fssystem_aes_xts_storage_external.cpp b/libstratosphere/source/fssystem/fssystem_aes_xts_storage_external.cpp index 922c5c96..4f9a45fd 100644 --- a/libstratosphere/source/fssystem/fssystem_aes_xts_storage_external.cpp +++ b/libstratosphere/source/fssystem/fssystem_aes_xts_storage_external.cpp @@ -111,7 +111,7 @@ namespace ams::fssystem { R_UNLESS(buffer != nullptr, fs::ResultNullptrArgument()); /* Ensure we can encrypt. */ - R_UNLESS(m_decrypt_function != nullptr, fs::ResultNullptrArgument()); + R_UNLESS(m_encrypt_function != nullptr, fs::ResultNullptrArgument()); /* We can only write at block aligned offsets. */ R_UNLESS(util::IsAligned(offset, AesBlockSize), fs::ResultInvalidArgument());