vlc | branch: master | Rémi Denis-Courmont <[email protected]> | Mon Nov 30 18:55:46 2015 +0200| [4b0d235874a044ed33a364a5fcc76dd643eaab5c] | committer: Rémi Denis-Courmont
decoder: unblock picture allocation at exit > http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=4b0d235874a044ed33a364a5fcc76dd643eaab5c --- src/input/decoder.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/input/decoder.c b/src/input/decoder.c index 70f22c2..c4fb6a1 100644 --- a/src/input/decoder.c +++ b/src/input/decoder.c @@ -1761,6 +1761,16 @@ void input_DecoderDelete( decoder_t *p_dec ) vlc_mutex_lock( &p_owner->lock ); p_owner->b_waiting = false; vlc_cond_signal( &p_owner->wait_request ); + + /* If the video output is paused or slow, or if the picture pool size was + * under-estimated (e.g. greedy video filter, buggy decoder...), the + * the picture pool may be empty, and the decoder thread or any decoder + * module worker threads may be stuck waiting for free picture buffers. + * + * This unblocks the thread, allowing the decoder module to join all its + * worker threads (if any) and the decoder thread to terminate. */ + if( p_owner->p_vout != NULL ) + vout_Cancel( p_owner->p_vout ); vlc_mutex_unlock( &p_owner->lock ); vlc_join( p_owner->thread, NULL ); _______________________________________________ vlc-commits mailing list [email protected] https://mailman.videolan.org/listinfo/vlc-commits
