ape: fix seeking
authorPaul B Mahol <onemda@gmail.com>
Fri, 3 Feb 2012 18:30:18 +0000 (18:30 +0000)
committerJustin Ruggles <justin.ruggles@gmail.com>
Sat, 4 Feb 2012 19:32:33 +0000 (14:32 -0500)
Signed-off-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Justin Ruggles <justin.ruggles@gmail.com>
libavformat/ape.c

index 080e0ba..345648e 100644 (file)
@@ -406,6 +406,8 @@ static int ape_read_seek(AVFormatContext *s, int stream_index, int64_t timestamp
     if (index < 0)
         return -1;
 
+    if (avio_seek(s->pb, st->index_entries[index].pos, SEEK_SET) < 0)
+        return -1;
     ape->currentframe = index;
     return 0;
 }