[FFmpeg-devel] [PATCH] matroskadec: reset num_levels on seek.

Aurelien Jacobs aurel at gnuage.org
Sun Feb 12 23:11:12 CET 2012


On Sun, Feb 12, 2012 at 08:01:36PM +0100, Michael Niedermayer wrote:
> On Sun, Feb 12, 2012 at 02:08:05PM +0100, Reimar Döffinger wrote:
> > Otherwise when we run into levels beyond the max. allowed
> > playback will be permanently broken.
> > 
> > Signed-off-by: Reimar Döffinger <Reimar.Doeffinger at gmx.de>
> 
> this is probably ok

Indeed this looks OK, provided that you verified that after seeking and
then letting play, nothing wrong happen when reaching the end of the
file.

And yes, CC is welcome. I generally can't follow closely the list.

Aurel

> > ---
> >  libavformat/matroskadec.c |    1 +
> >  1 files changed, 1 insertions(+), 0 deletions(-)
> > 
> > diff --git a/libavformat/matroskadec.c b/libavformat/matroskadec.c
> > index df54762..5c1cc87 100644
> > --- a/libavformat/matroskadec.c
> > +++ b/libavformat/matroskadec.c
> > @@ -2067,6 +2067,7 @@ static int matroska_read_seek(AVFormatContext *s, int stream_index,
> >      matroska->skip_to_keyframe = !(flags & AVSEEK_FLAG_ANY);
> >      matroska->skip_to_timecode = st->index_entries[index].timestamp;
> >      matroska->done = 0;
> > +    matroska->num_levels = 0;
> >      ff_update_cur_dts(s, st, st->index_entries[index].timestamp);
> >      return 0;
> >  }
> 



> _______________________________________________
> ffmpeg-devel mailing list
> ffmpeg-devel at ffmpeg.org
> http://ffmpeg.org/mailman/listinfo/ffmpeg-devel



More information about the ffmpeg-devel mailing list