diff options
author | David <25727384+ogniK5377@users.noreply.github.com> | 2018-09-19 17:59:01 +0200 |
---|---|---|
committer | bunnei <bunneidev@gmail.com> | 2018-09-19 17:59:01 +0200 |
commit | 0432af5ad1ec34f02071f6fdc5fc78149b059f18 (patch) | |
tree | b9a9e004bf0e6b1a8a4a7424228513ace0301bfd /src/core/hle/service | |
parent | Merge pull request #1356 from degasus/hotfix (diff) | |
download | yuzu-0432af5ad1ec34f02071f6fdc5fc78149b059f18.tar yuzu-0432af5ad1ec34f02071f6fdc5fc78149b059f18.tar.gz yuzu-0432af5ad1ec34f02071f6fdc5fc78149b059f18.tar.bz2 yuzu-0432af5ad1ec34f02071f6fdc5fc78149b059f18.tar.lz yuzu-0432af5ad1ec34f02071f6fdc5fc78149b059f18.tar.xz yuzu-0432af5ad1ec34f02071f6fdc5fc78149b059f18.tar.zst yuzu-0432af5ad1ec34f02071f6fdc5fc78149b059f18.zip |
Diffstat (limited to 'src/core/hle/service')
-rw-r--r-- | src/core/hle/service/nifm/nifm.cpp | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/src/core/hle/service/nifm/nifm.cpp b/src/core/hle/service/nifm/nifm.cpp index ed4f5f539..b6075f256 100644 --- a/src/core/hle/service/nifm/nifm.cpp +++ b/src/core/hle/service/nifm/nifm.cpp @@ -65,7 +65,7 @@ private: LOG_WARNING(Service_NIFM, "(STUBBED) called"); IPC::ResponseBuilder rb{ctx, 3}; rb.Push(RESULT_SUCCESS); - rb.Push<u32>(0); + rb.Push<u32>(3); } void GetResult(Kernel::HLERequestContext& ctx) { @@ -114,10 +114,11 @@ public: private: void GetClientId(Kernel::HLERequestContext& ctx) { + static constexpr u32 client_id = 1; LOG_WARNING(Service_NIFM, "(STUBBED) called"); IPC::ResponseBuilder rb{ctx, 4}; rb.Push(RESULT_SUCCESS); - rb.Push<u64>(0); + rb.Push<u64>(client_id); // Client ID needs to be non zero otherwise it's considered invalid } void CreateScanRequest(Kernel::HLERequestContext& ctx) { IPC::ResponseBuilder rb{ctx, 2, 0, 1}; @@ -141,10 +142,16 @@ private: rb.Push(RESULT_SUCCESS); } void CreateTemporaryNetworkProfile(Kernel::HLERequestContext& ctx) { - IPC::ResponseBuilder rb{ctx, 2, 0, 1}; + ASSERT_MSG(ctx.GetReadBufferSize() == 0x17c, "NetworkProfileData is not the correct size"); + u128 uuid{}; + auto buffer = ctx.ReadBuffer(); + std::memcpy(&uuid, buffer.data() + 8, sizeof(u128)); + + IPC::ResponseBuilder rb{ctx, 6, 0, 1}; rb.Push(RESULT_SUCCESS); rb.PushIpcInterface<INetworkProfile>(); + rb.PushRaw<u128>(uuid); LOG_DEBUG(Service_NIFM, "called"); } |