From 726f8adfe3f3b4970b9d384d85838d644e736676 Mon Sep 17 00:00:00 2001 From: yellows8 Date: Sat, 19 May 2018 21:43:12 -0400 Subject: [PATCH] Replaced the hard-coded timeout error constant in nvgfxEventWait() with the one from result.h. This fixes an issue caused by a past commit. --- nx/source/gfx/nvgfx.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/nx/source/gfx/nvgfx.c b/nx/source/gfx/nvgfx.c index 5b55e0f8..e54847ab 100644 --- a/nx/source/gfx/nvgfx.c +++ b/nx/source/gfx/nvgfx.c @@ -420,11 +420,12 @@ void nvgfxExit(void) { Result nvgfxEventWait(u32 syncpt_id, u32 threshold, s32 timeout) { Result rc=0; + Result timeout_rc = MAKERESULT(Module_LibnxNvidia, LibnxNvidiaError_Timeout); if (R_SUCCEEDED(rc)) { do { rc = nvioctlNvhostCtrl_EventWait(g_nvgfx_fd_nvhostctrl, syncpt_id, threshold, timeout, 0, &g_nvgfx_nvhostctrl_eventres); - } while(rc==5);//timeout error + } while(rc==timeout_rc); } //Official sw only uses the below block when event-waiting timeout occurs.