Browse Source

lavd/sdl: make waiting spurious wakeup aware

Signed-off-by: Lukasz Marek <lukasz.m.luki@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
tags/n2.2-rc1
Lukasz Marek Michael Niedermayer 11 years ago
parent
commit
18c3313e65
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      libavdevice/sdl.c

+ 1
- 1
libavdevice/sdl.c View File

@@ -292,7 +292,7 @@ static int sdl_write_header(AVFormatContext *s)


/* wait until the video system has been inited */ /* wait until the video system has been inited */
SDL_LockMutex(sdl->mutex); SDL_LockMutex(sdl->mutex);
if (!sdl->inited) {
while (!sdl->inited) {
SDL_CondWait(sdl->init_cond, sdl->mutex); SDL_CondWait(sdl->init_cond, sdl->mutex);
} }
SDL_UnlockMutex(sdl->mutex); SDL_UnlockMutex(sdl->mutex);


Loading…
Cancel
Save