[FFmpeg-cvslog] avcodec/pthread_slice: Use av_freep() to avoid leaving stale pointers in memory

Michael Niedermayer git at videolan.org
Sat Nov 1 11:37:55 CET 2014


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Sat Nov  1 11:22:06 2014 +0100| [e5054c8eed339283f352c70d191b35b3c3db227e] | committer: Michael Niedermayer

avcodec/pthread_slice: Use av_freep() to avoid leaving stale pointers in memory

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=e5054c8eed339283f352c70d191b35b3c3db227e
---

 libavcodec/pthread_slice.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavcodec/pthread_slice.c b/libavcodec/pthread_slice.c
index fea989f..b948e16 100644
--- a/libavcodec/pthread_slice.c
+++ b/libavcodec/pthread_slice.c
@@ -120,7 +120,7 @@ void ff_slice_thread_free(AVCodecContext *avctx)
     pthread_mutex_destroy(&c->current_job_lock);
     pthread_cond_destroy(&c->current_job_cond);
     pthread_cond_destroy(&c->last_job_cond);
-    av_free(c->workers);
+    av_freep(&c->workers);
     av_freep(&avctx->internal->thread_ctx);
 }
 



More information about the ffmpeg-cvslog mailing list