From 170e19d4eab455ad4d28ad72799cc6687692392d Mon Sep 17 00:00:00 2001 From: bunnei Date: Tue, 17 Jul 2018 00:05:13 -0400 Subject: nvflinger: Fix for BufferQueue event handling. --- src/core/hle/service/vi/vi.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/core/hle/service/vi') diff --git a/src/core/hle/service/vi/vi.cpp b/src/core/hle/service/vi/vi.cpp index f3765b555..e094510bf 100644 --- a/src/core/hle/service/vi/vi.cpp +++ b/src/core/hle/service/vi/vi.cpp @@ -495,7 +495,7 @@ private: ctx.WriteBuffer(response.Serialize()); } else { // Wait the current thread until a buffer becomes available - auto wait_event = ctx.SleepClientThread( + ctx.SleepClientThread( Kernel::GetCurrentThread(), "IHOSBinderDriver::DequeueBuffer", -1, [=](Kernel::SharedPtr thread, Kernel::HLERequestContext& ctx, ThreadWakeupReason reason) { @@ -506,8 +506,8 @@ private: ctx.WriteBuffer(response.Serialize()); IPC::ResponseBuilder rb{ctx, 2}; rb.Push(RESULT_SUCCESS); - }); - buffer_queue->SetBufferWaitEvent(std::move(wait_event)); + }, + buffer_queue->GetBufferWaitEvent()); } } else if (transaction == TransactionId::RequestBuffer) { IGBPRequestBufferRequestParcel request{ctx.ReadBuffer()}; @@ -565,7 +565,7 @@ private: LOG_WARNING(Service_VI, "(STUBBED) called id={}, unknown={:08X}", id, unknown); IPC::ResponseBuilder rb{ctx, 2, 1}; rb.Push(RESULT_SUCCESS); - rb.PushCopyObjects(buffer_queue->GetNativeHandle()); + rb.PushCopyObjects(buffer_queue->GetBufferWaitEvent()); } std::shared_ptr nv_flinger; -- cgit v1.2.3