[FFmpeg-cvslog] [PATCH] Fix crash when initializing multi-threaded decoding for corrupted file.
Cheng Sun
git at videolan.org
Sun Nov 27 00:39:12 CET 2011
ffmpeg | branch: master | Cheng Sun <cheng.sun at ymail.com> | Sat Nov 26 10:45:36 2011 -0800| [e524eadbf8ac568fcab7fa8f9520fad013beb91a] | committer: Ronald S. Bultje
[PATCH] Fix crash when initializing multi-threaded decoding for corrupted file.
Signed-off-by: Ronald S. Bultje <rsbultje at gmail.com>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=e524eadbf8ac568fcab7fa8f9520fad013beb91a
---
libavcodec/pthread.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/libavcodec/pthread.c b/libavcodec/pthread.c
index 3364376..dae28e6 100644
--- a/libavcodec/pthread.c
+++ b/libavcodec/pthread.c
@@ -651,7 +651,8 @@ static void frame_thread_free(AVCodecContext *avctx, int thread_count)
pthread_cond_signal(&p->input_cond);
pthread_mutex_unlock(&p->mutex);
- pthread_join(p->thread, NULL);
+ if (p->thread)
+ pthread_join(p->thread, NULL);
if (codec->close)
codec->close(p->avctx);
More information about the ffmpeg-cvslog
mailing list