]> git.sesse.net Git - ffmpeg/commitdiff
matroskadec: fix SRT subtitle duration
authorJohn Stebbins <stebbins@jetheaddev.com>
Thu, 22 Dec 2016 17:23:30 +0000 (09:23 -0800)
committerJohn Stebbins <stebbins@jetheaddev.com>
Sat, 24 Dec 2016 16:33:17 +0000 (08:33 -0800)
The codec id for SRT was changed and conditionals were not updated.

libavformat/matroskadec.c

index 80167309650c9c8df499b49ea784b0c2aaa2f09a..a3954b0c4e98dae2036f5b7fc2738373b4fed595 100644 (file)
@@ -2439,11 +2439,11 @@ static int matroska_parse_frame(MatroskaDemuxContext *matroska,
     else
         pkt->pts = timecode;
     pkt->pos = pos;
-    if (track->type != MATROSKA_TRACK_TYPE_SUBTITLE || st->codecpar->codec_id == AV_CODEC_ID_TEXT)
+    if (track->type != MATROSKA_TRACK_TYPE_SUBTITLE || st->codecpar->codec_id == AV_CODEC_ID_SRT)
         pkt->duration = duration;
 #if FF_API_CONVERGENCE_DURATION
 FF_DISABLE_DEPRECATION_WARNINGS
-    if (st->codecpar->codec_id == AV_CODEC_ID_TEXT)
+    if (st->codecpar->codec_id == AV_CODEC_ID_SRT)
         pkt->convergence_duration = duration;
 FF_ENABLE_DEPRECATION_WARNINGS
 #endif