diff mbox

[FFmpeg-devel,3/4] avformat/concatdec: fix cur_dts based duration calculation with nonzero stream start_time

Message ID 20181122003907.12088-3-cus@passwd.hu
State Accepted
Commit 679cbd8f18719f470f7107ed0a7fbef1905ee85a
Headers show

Commit Message

Marton Balint Nov. 22, 2018, 12:39 a.m. UTC
Signed-off-by: Marton Balint <cus@passwd.hu>
---
 libavformat/concatdec.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Nicolas George Dec. 9, 2018, 11:25 a.m. UTC | #1
Marton Balint (2018-11-22):
> Signed-off-by: Marton Balint <cus@passwd.hu>
> ---
>  libavformat/concatdec.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

I suppose it is valid.

Regards,
diff mbox

Patch

diff --git a/libavformat/concatdec.c b/libavformat/concatdec.c
index 97a0faea14..ebc50324cc 100644
--- a/libavformat/concatdec.c
+++ b/libavformat/concatdec.c
@@ -325,7 +325,7 @@  static int64_t get_best_effort_duration(ConcatFile *file, AVFormatContext *avf)
     if (avf->duration > 0)
         return avf->duration - (file->file_inpoint - file->file_start_time);
     if (file->next_dts != AV_NOPTS_VALUE)
-        return file->next_dts - (file->file_inpoint - file->file_start_time);
+        return file->next_dts - file->file_inpoint;
     return AV_NOPTS_VALUE;
 }