diff options
| author | ameerj <52414509+ameerj@users.noreply.github.com> | 2022-12-25 13:42:32 -0500 |
|---|---|---|
| committer | ameerj <52414509+ameerj@users.noreply.github.com> | 2022-12-25 17:04:02 -0500 |
| commit | 7ffd62424804eceb73f01b1c4e8dc216134c8295 (patch) | |
| tree | 2bfe2a9b5d0a3f0857c73475cbdf24f6fe66c740 /src/core/hle/service/jit/jit.cpp | |
| parent | fbc375f0de26342a22c52bb78e14b4f78d2243c1 (diff) | |
service: Use ReadBufferSpan where it is trivial to do so
Diffstat (limited to 'src/core/hle/service/jit/jit.cpp')
| -rw-r--r-- | src/core/hle/service/jit/jit.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/core/hle/service/jit/jit.cpp b/src/core/hle/service/jit/jit.cpp index 8f2920c51..534639ff9 100644 --- a/src/core/hle/service/jit/jit.cpp +++ b/src/core/hle/service/jit/jit.cpp @@ -62,7 +62,7 @@ public: const auto parameters{rp.PopRaw<InputParameters>()}; // Optional input/output buffers - std::vector<u8> input_buffer{ctx.CanReadBuffer() ? ctx.ReadBuffer() : std::vector<u8>()}; + const auto input_buffer{ctx.CanReadBuffer() ? ctx.ReadBufferSpan() : std::span<const u8>()}; std::vector<u8> output_buffer(ctx.CanWriteBuffer() ? ctx.GetWriteBufferSize() : 0); // Function call prototype: @@ -132,7 +132,7 @@ public: const auto command{rp.PopRaw<u64>()}; // Optional input/output buffers - std::vector<u8> input_buffer{ctx.CanReadBuffer() ? ctx.ReadBuffer() : std::vector<u8>()}; + const auto input_buffer{ctx.CanReadBuffer() ? ctx.ReadBufferSpan() : std::span<const u8>()}; std::vector<u8> output_buffer(ctx.CanWriteBuffer() ? ctx.GetWriteBufferSize() : 0); // Function call prototype: @@ -176,7 +176,7 @@ public: IPC::RequestParser rp{ctx}; const auto tmem_size{rp.PopRaw<u64>()}; const auto tmem_handle{ctx.GetCopyHandle(0)}; - const auto nro_plugin{ctx.ReadBuffer(1)}; + const auto nro_plugin{ctx.ReadBufferSpan(1)}; if (tmem_size == 0) { LOG_ERROR(Service_JIT, "attempted to load plugin with empty transfer memory"); |
