mirror of
https://github.com/Genymobile/scrcpy.git
synced 2026-04-21 01:33:36 +00:00
Handle condition variable failure
Add condition variables function wrappers to handle unexpected failure.
This commit is contained in:
parent
c4266e487b
commit
b9c9466d65
3 changed files with 16 additions and 2 deletions
|
|
@ -24,7 +24,7 @@ static void push_frame(struct decoder *decoder) {
|
|||
mutex_lock(frames->mutex);
|
||||
if (!decoder->skip_frames) {
|
||||
while (!frames->rendering_frame_consumed) {
|
||||
SDL_CondWait(frames->rendering_frame_consumed_cond, frames->mutex);
|
||||
cond_wait(frames->rendering_frame_consumed_cond, frames->mutex);
|
||||
}
|
||||
} else if (!frames->rendering_frame_consumed) {
|
||||
SDL_LogInfo(SDL_LOG_CATEGORY_RENDER, "Skip frame");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue