[FFmpeg-cvslog] avformat/swfdec: Do not error out on pixel format changes

Michael Niedermayer git at videolan.org
Wed Jul 8 12:56:18 CEST 2015


ffmpeg | branch: release/2.7 | Michael Niedermayer <michaelni at gmx.at> | Wed Jul  8 02:43:02 2015 +0200| [f921a47fae3e0625372de246cda3bc801b5ce5fc] | committer: Carl Eugen Hoyos

avformat/swfdec: Do not error out on pixel format changes

Instead print an error and continue

Fixes Ticket4702

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
(cherry picked from commit 6a1204a1a46674084b1e6b92562f81aaab7aac69)

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

 libavformat/swfdec.c |    6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/libavformat/swfdec.c b/libavformat/swfdec.c
index d34d3d9..570a4f5 100644
--- a/libavformat/swfdec.c
+++ b/libavformat/swfdec.c
@@ -407,10 +407,8 @@ static int swf_read_packet(AVFormatContext *s, AVPacket *pkt)
             }
             if (st->codec->pix_fmt != AV_PIX_FMT_NONE && st->codec->pix_fmt != pix_fmt) {
                 av_log(s, AV_LOG_ERROR, "pixel format change unsupported\n");
-                res = AVERROR_PATCHWELCOME;
-                goto bitmap_end;
-            }
-            st->codec->pix_fmt = pix_fmt;
+            }else
+                st->codec->pix_fmt = pix_fmt;
 
             if (linesize * height > pkt->size) {
                 res = AVERROR_INVALIDDATA;



More information about the ffmpeg-cvslog mailing list