034413405f1fb4c47f2efdd7aba2389675878b26
[packages/trusty/cirros-testvm.git] / cirros-testvm / src-cirros / buildroot-2015.05 / package / ffmpeg / 0003-if-av_read_packet-returns-AVERROR_IO-we-are-done.-ff.patch
1 From 54200b3e6009c6870e33c02c8bbcf023fcd92cac Mon Sep 17 00:00:00 2001
2 From: Cory Fields <theuni-nospam-@xbmc.org>
3 Date: Mon, 28 Jun 2010 01:55:31 -0400
4 Subject: [PATCH 03/13] if av_read_packet returns AVERROR_IO, we are done.
5  ffmpeg's codecs might or might not handle returning any completed demuxed
6  packets correctly
7
8 Patch part of the XBMC patch set for ffmpeg, downloaded from
9 https://github.com/xbmc/FFmpeg/.
10
11 Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
12 Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
13 ---
14  libavformat/utils.c | 2 ++
15  1 file changed, 2 insertions(+)
16
17 diff --git a/libavformat/utils.c b/libavformat/utils.c
18 index ae6347a..3e8af50 100644
19 --- a/libavformat/utils.c
20 +++ b/libavformat/utils.c
21 @@ -1304,6 +1304,8 @@ static int read_frame_internal(AVFormatContext *s, AVPacket *pkt)
22          if (ret < 0) {
23              if (ret == AVERROR(EAGAIN))
24                  return ret;
25 +            if (ret == AVERROR(EIO))
26 +                return ret;
27              /* flush the parsers */
28              for (i = 0; i < s->nb_streams; i++) {
29                  st = s->streams[i];
30 -- 
31 2.1.0
32