---
 libavformat/ape.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/libavformat/ape.c b/libavformat/ape.c
index 345648e..a6e9bf1 100644
--- a/libavformat/ape.c
+++ b/libavformat/ape.c
@@ -361,7 +361,8 @@ static int ape_read_packet(AVFormatContext * s, AVPacket * 
pkt)
     if (ape->currentframe > ape->totalframes)
         return AVERROR(EIO);
 
-    avio_seek (s->pb, ape->frames[ape->currentframe].pos, SEEK_SET);
+    if (avio_seek(s->pb, ape->frames[ape->currentframe].pos, SEEK_SET) < 0)
+        return AVERROR(EIO);
 
     /* Calculate how many blocks there are in this frame */
     if (ape->currentframe == (ape->totalframes - 1))
-- 
1.7.1

_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel

Reply via email to