diff options
author | liamwhite <liamwhite@users.noreply.github.com> | 2024-01-30 20:29:41 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-01-30 20:29:41 +0100 |
commit | ffe3984353135ccab79649b78c82e9fdf5e1c760 (patch) | |
tree | df76a4321f6cddcedd75b2899969b96c3429c8a0 /src | |
parent | Merge pull request #12859 from german77/led (diff) | |
parent | cmif_serialization: fix LargeData types (diff) | |
download | yuzu-ffe3984353135ccab79649b78c82e9fdf5e1c760.tar yuzu-ffe3984353135ccab79649b78c82e9fdf5e1c760.tar.gz yuzu-ffe3984353135ccab79649b78c82e9fdf5e1c760.tar.bz2 yuzu-ffe3984353135ccab79649b78c82e9fdf5e1c760.tar.lz yuzu-ffe3984353135ccab79649b78c82e9fdf5e1c760.tar.xz yuzu-ffe3984353135ccab79649b78c82e9fdf5e1c760.tar.zst yuzu-ffe3984353135ccab79649b78c82e9fdf5e1c760.zip |
Diffstat (limited to 'src')
-rw-r--r-- | src/core/hle/service/cmif_serialization.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/core/hle/service/cmif_serialization.h b/src/core/hle/service/cmif_serialization.h index 5eabf51fe..315475e71 100644 --- a/src/core/hle/service/cmif_serialization.h +++ b/src/core/hle/service/cmif_serialization.h @@ -283,7 +283,7 @@ void ReadInArgument(bool is_domain, CallArguments& args, const u8* raw_data, HLE return ReadInArgument<MethodArguments, CallArguments, PrevAlign, DataOffset, HandleIndex + 1, InBufferIndex, OutBufferIndex, RawDataFinished, ArgIndex + 1>(is_domain, args, raw_data, ctx, temp); } else if constexpr (ArgumentTraits<ArgType>::Type == ArgumentType::InLargeData) { - constexpr size_t BufferSize = sizeof(ArgType); + constexpr size_t BufferSize = sizeof(typename ArgType::Type); // Clear the existing data. std::memset(&std::get<ArgIndex>(args), 0, BufferSize); @@ -324,7 +324,7 @@ void ReadInArgument(bool is_domain, CallArguments& args, const u8* raw_data, HLE return ReadInArgument<MethodArguments, CallArguments, PrevAlign, DataOffset, HandleIndex, InBufferIndex + 1, OutBufferIndex, RawDataFinished, ArgIndex + 1>(is_domain, args, raw_data, ctx, temp); } else if constexpr (ArgumentTraits<ArgType>::Type == ArgumentType::OutLargeData) { - constexpr size_t BufferSize = sizeof(ArgType); + constexpr size_t BufferSize = sizeof(typename ArgType::Type); // Clear the existing data. std::memset(&std::get<ArgIndex>(args).raw, 0, BufferSize); @@ -394,7 +394,7 @@ void WriteOutArgument(bool is_domain, CallArguments& args, u8* raw_data, HLERequ return WriteOutArgument<MethodArguments, CallArguments, PrevAlign, DataOffset, OutBufferIndex, RawDataFinished, ArgIndex + 1>(is_domain, args, raw_data, ctx, temp); } else if constexpr (ArgumentTraits<ArgType>::Type == ArgumentType::OutLargeData) { - constexpr size_t BufferSize = sizeof(ArgType); + constexpr size_t BufferSize = sizeof(typename ArgType::Type); ASSERT(ctx.CanWriteBuffer(OutBufferIndex)); if constexpr (ArgType::Attr & BufferAttr_HipcAutoSelect) { |