From dac532f278c50002ed2fae5c7e2c5b3edfc4f96e Mon Sep 17 00:00:00 2001
Date: Mon, 18 Feb 2013 11:34:09 +0000
Subject: [PATCH] if-av_read_packet-returns-AVERROR_IO-we-are-done.-ff

---
 libavformat/utils.c |    2 ++
 1 file changed, 2 insertions(+)

diff --git a/libavformat/utils.c b/libavformat/utils.c
index 4b8bcd1..bdb9d17 100644
--- a/libavformat/utils.c
+++ b/libavformat/utils.c
@@ -1386,6 +1386,8 @@ static int read_frame_internal(AVFormatContext *s, AVPacket *pkt)
         if (ret < 0) {
             if (ret == AVERROR(EAGAIN))
                 return ret;
+            if (ret == AVERROR(EIO))
+                return ret;
             /* flush the parsers */
             for(i = 0; i < s->nb_streams; i++) {
                 st = s->streams[i];
-- 
1.7.10.4

