On Mon, Dec 15, 2014 at 06:53:19PM +0100, Nicolas George wrote: > Le quintidi 25 frimaire, an CCXXIII, Michael Niedermayer a écrit : > > Lines: 36 > > > > Fixes Ticket3598 > > > > Signed-off-by: Michael Niedermayer <michae...@gmx.at> > > --- > > libavformat/concatdec.c | 11 ++++++++--- > > 1 file changed, 8 insertions(+), 3 deletions(-) > > > > diff --git a/libavformat/concatdec.c b/libavformat/concatdec.c > > index a2584d7..253951a 100644 > > --- a/libavformat/concatdec.c > > +++ b/libavformat/concatdec.c > > @@ -512,9 +512,14 @@ static int concat_read_packet(AVFormatContext *avf, > > AVPacket *pkt) > > av_ts2str(pkt->pts), av_ts2timestr(pkt->pts, &st->time_base), > > av_ts2str(pkt->dts), av_ts2timestr(pkt->dts, &st->time_base)); > > > > - delta = av_rescale_q(cat->cur_file->start_time - cat->avf->start_time, > > - AV_TIME_BASE_Q, > > - cat->avf->streams[pkt->stream_index]->time_base); > > + if (cat->avf->start_time == AV_NOPTS_VALUE) > > + delta = av_rescale_q(cat->cur_file->start_time, > > + AV_TIME_BASE_Q, > > + > > cat->avf->streams[pkt->stream_index]->time_base); > > + else > > + delta = av_rescale_q(cat->cur_file->start_time - > > cat->avf->start_time, > > + AV_TIME_BASE_Q, > > + > > cat->avf->streams[pkt->stream_index]->time_base); > > if (pkt->pts != AV_NOPTS_VALUE) > > pkt->pts += delta; > > if (pkt->dts != AV_NOPTS_VALUE) >
> I am ok in principle, but I like it better written like [PATCH 1/2]: less > code duplication, less changed lines. applied > > Also, I wonder if there is any disadvantage in [PATCH 2/2], which would fix > this particular problem too. dunno thx [...] -- Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB When you are offended at any man's fault, turn to yourself and study your own failings. Then you will forget your anger. -- Epictetus
signature.asc
Description: Digital signature
_______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel