From 22dcb39adb1be759429e4f5bf86f21f5466c57a5 Mon Sep 17 00:00:00 2001 From: Geoffrey McRae Date: Sun, 3 Mar 2019 23:45:37 +1100 Subject: [PATCH] [c-host] app: fix deadlock on reinit --- c-host/app.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/c-host/app.c b/c-host/app.c index c21e34a5..58fcb0ec 100644 --- a/c-host/app.c +++ b/c-host/app.c @@ -86,6 +86,7 @@ static int frameThread(void * opaque) { if (!os_waitEvent(app.frameEvent) || !app.running) break; + DEBUG_INFO("Frame"); CaptureFrame frame; frame.data = app.frame[frameIndex]; @@ -288,7 +289,10 @@ int app_main() exitcode = -1; goto finish; } - break; + + // start signalled + os_signalEvent(app.updateEvent); + continue; case CAPTURE_RESULT_ERROR: DEBUG_ERROR("Capture interface reported a fatal error");