[c-host] resend the last on client reconnect if a timeout occurs

This commit is contained in:
Geoffrey McRae
2019-05-28 14:24:48 +10:00
parent 3d426ccef8
commit 7d26027752
4 changed files with 45 additions and 28 deletions

View File

@@ -238,11 +238,8 @@ static CaptureResult nvfbc_capture()
static CaptureResult nvfbc_getFrame(CaptureFrame * frame)
{
if (!os_waitEvent(this->frameEvent, TIMEOUT_INFINITE))
{
DEBUG_ERROR("Failed to wait on the frame event");
return CAPTURE_RESULT_ERROR;
}
if (!os_waitEvent(this->frameEvent, 1000))
return CAPTURE_RESULT_TIMEOUT;
if (this->stop)
return CAPTURE_RESULT_REINIT;