summaryrefslogtreecommitdiffstats
path: root/contrib/ffmpeg
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/ffmpeg')
-rw-r--r--contrib/ffmpeg/A05-mkv-seek.patch20
1 files changed, 20 insertions, 0 deletions
diff --git a/contrib/ffmpeg/A05-mkv-seek.patch b/contrib/ffmpeg/A05-mkv-seek.patch
new file mode 100644
index 000000000..7ac47014a
--- /dev/null
+++ b/contrib/ffmpeg/A05-mkv-seek.patch
@@ -0,0 +1,20 @@
+diff --git a/libavformat/matroskadec.c b/libavformat/matroskadec.c
+index 57a8f62..60f6c69 100644
+--- a/libavformat/matroskadec.c
++++ b/libavformat/matroskadec.c
+@@ -1903,6 +1903,7 @@ static int matroska_read_seek(AVFormatContext *s, int stream_index,
+
+ if ((index = av_index_search_timestamp(st, timestamp, flags)) < 0) {
+ avio_seek(s->pb, st->index_entries[st->nb_index_entries-1].pos, SEEK_SET);
++ matroska->current_id = 0;
+ while ((index = av_index_search_timestamp(st, timestamp, flags)) < 0) {
+ matroska_clear_queue(matroska);
+ if (matroska_parse_cluster(matroska) < 0)
+@@ -1931,6 +1932,7 @@ static int matroska_read_seek(AVFormatContext *s, int stream_index,
+ }
+
+ avio_seek(s->pb, st->index_entries[index_min].pos, SEEK_SET);
++ matroska->current_id = 0;
+ matroska->skip_to_keyframe = !(flags & AVSEEK_FLAG_ANY);
+ matroska->skip_to_timecode = st->index_entries[index].timestamp;
+ matroska->done = 0;