[FFmpeg-cvslog] Use av_sat_sub64() when updating pts by duration.
Dale Curtis
git at videolan.org
Fri May 29 21:12:51 EEST 2020
ffmpeg | branch: master | Dale Curtis <dalecurtis at chromium.org> | Thu May 14 14:33:55 2020 -0700| [fc54db32652bc830fba002da19c2ba9ba4508ca5] | committer: Michael Niedermayer
Use av_sat_sub64() when updating pts by duration.
Signed-off-by: Dale Curtis <dalecurtis at chromium.org>
Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=fc54db32652bc830fba002da19c2ba9ba4508ca5
---
libavformat/oggparsetheora.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libavformat/oggparsetheora.c b/libavformat/oggparsetheora.c
index 87a676fe48..c481a79d4b 100644
--- a/libavformat/oggparsetheora.c
+++ b/libavformat/oggparsetheora.c
@@ -191,7 +191,7 @@ static int theora_packet(AVFormatContext *s, int idx)
pts = theora_gptopts(s, idx, os->granule, NULL);
if (pts != AV_NOPTS_VALUE)
- pts -= duration;
+ pts = av_sat_sub64(pts, duration);
os->lastpts = os->lastdts = pts;
if(s->streams[idx]->start_time == AV_NOPTS_VALUE) {
s->streams[idx]->start_time = os->lastpts;
More information about the ffmpeg-cvslog
mailing list