[FFmpeg-cvslog] pthread: Fix mixing of declarations and statements.

Michael Niedermayer git at videolan.org
Sun Mar 18 01:35:14 CET 2012


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Sat Mar 17 23:49:56 2012 +0100| [79a19f6e589b302de4502fd4cb1e9d800cfa4179] | committer: Michael Niedermayer

pthread: Fix mixing of declarations and statements.

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

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

 libavcodec/pthread.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/libavcodec/pthread.c b/libavcodec/pthread.c
index d02f684..7834922 100644
--- a/libavcodec/pthread.c
+++ b/libavcodec/pthread.c
@@ -895,6 +895,7 @@ error:
 void ff_thread_flush(AVCodecContext *avctx)
 {
     FrameThreadContext *fctx = avctx->thread_opaque;
+    int i;
 
     if (!avctx->thread_opaque) return;
 
@@ -910,7 +911,7 @@ void ff_thread_flush(AVCodecContext *avctx)
     fctx->delaying = 1;
     fctx->prev_thread = NULL;
     // Make sure decode flush calls with size=0 won't return old frames
-    for (int i = 0; i < avctx->thread_count; i++)
+    for (i = 0; i < avctx->thread_count; i++)
         fctx->threads[i].got_frame = 0;
 }
 



More information about the ffmpeg-cvslog mailing list