[FFmpeg-cvslog] avformat_find_stream_info: move ret init down from flush codecs.

Michael Niedermayer git at videolan.org
Tue Jul 2 15:14:17 CEST 2013


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Tue Jul  2 15:06:43 2013 +0200| [d59ec0adbbc49507202cfedd034870a06cb5ec2a] | committer: Michael Niedermayer

avformat_find_stream_info: move ret init down from flush codecs.

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

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

 libavformat/utils.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libavformat/utils.c b/libavformat/utils.c
index 9577968..f7822ee 100644
--- a/libavformat/utils.c
+++ b/libavformat/utils.c
@@ -2888,8 +2888,6 @@ int avformat_find_stream_info(AVFormatContext *ic, AVDictionary **options)
         int err = 0;
         av_init_packet(&empty_pkt);
 
-        if (ret >= 0 && ic->nb_streams)
-        ret = -1; /* we could not have all the codec parameters before EOF */
         for(i=0;i<ic->nb_streams;i++) {
 
             st = ic->streams[i];
@@ -3016,6 +3014,8 @@ int avformat_find_stream_info(AVFormatContext *ic, AVDictionary **options)
     if(ic->probesize)
     estimate_timings(ic, old_offset);
 
+    if (ret >= 0 && ic->nb_streams)
+        ret = -1; /* we could not have all the codec parameters before EOF */
     for(i=0;i<ic->nb_streams;i++) {
         const char *errmsg;
         st = ic->streams[i];



More information about the ffmpeg-cvslog mailing list