[FFmpeg-cvslog] ape: Don't allow the seektable to be omitted

Martin Storsjö git at videolan.org
Thu Jan 16 21:51:29 CET 2014


ffmpeg | branch: release/0.10 | Martin Storsjö <martin at martin.st> | Wed Sep 11 22:29:33 2013 +0300| [f241d5aa1fa45d98c26accd0832c354e7ec64e5a] | committer: Luca Barbato

ape: Don't allow the seektable to be omitted

The seektable is required for filling in ape->frames[i].pos
further down.

Reported-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
CC: libav-stable at libav.org
Signed-off-by: Martin Storsjö <martin at martin.st>
(cherry picked from commit 183b9d843a9533774fabd3984a52f3987001acbc)
Signed-off-by: Luca Barbato <lu_zero at gentoo.org>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=f241d5aa1fa45d98c26accd0832c354e7ec64e5a
---

 libavformat/ape.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavformat/ape.c b/libavformat/ape.c
index 7d4cd39..2e5250b 100644
--- a/libavformat/ape.c
+++ b/libavformat/ape.c
@@ -255,7 +255,7 @@ static int ape_read_header(AVFormatContext * s, AVFormatParameters * ap)
                ape->totalframes);
         return -1;
     }
-    if (ape->seektablelength && (ape->seektablelength / sizeof(*ape->seektable)) < ape->totalframes) {
+    if (ape->seektablelength / sizeof(*ape->seektable) < ape->totalframes) {
         av_log(s, AV_LOG_ERROR,
                "Number of seek entries is less than number of frames: %zu vs. %"PRIu32"\n",
                ape->seektablelength / sizeof(*ape->seektable), ape->totalframes);



More information about the ffmpeg-cvslog mailing list