diff options
Diffstat (limited to 'src/demuxers/demux_smjpeg.c')
-rw-r--r-- | src/demuxers/demux_smjpeg.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/demuxers/demux_smjpeg.c b/src/demuxers/demux_smjpeg.c index 1619d36a3..643bf7059 100644 --- a/src/demuxers/demux_smjpeg.c +++ b/src/demuxers/demux_smjpeg.c @@ -21,7 +21,7 @@ * For more information on the SMJPEG file format, visit: * http://www.lokigames.com/development/smjpeg.php3 * - * $Id: demux_smjpeg.c,v 1.18 2002/10/06 03:48:13 komadori Exp $ + * $Id: demux_smjpeg.c,v 1.19 2002/10/12 17:11:59 jkeil Exp $ */ #ifdef HAVE_CONFIG_H @@ -32,6 +32,7 @@ #include <fcntl.h> #include <unistd.h> #include <pthread.h> +#include <sched.h> #include <string.h> #include <stdlib.h> @@ -123,6 +124,8 @@ static void *demux_smjpeg_loop (void *this_gen) { /* someone may want to interrupt us */ pthread_mutex_unlock( &this->mutex ); + /* give demux_*_stop a chance to interrupt us */ + sched_yield(); pthread_mutex_lock( &this->mutex ); /* load the next sample */ |