[FFmpeg-devel] [PATCH] avcodec/cfhd: Set dimensions unconditionally

Michael Niedermayer michael at niedermayer.cc
Fri Jun 10 20:58:37 CEST 2016


Fixes Ticket5215

Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
---
 libavcodec/cfhd.c |    5 +++++
 1 file changed, 5 insertions(+)

diff --git a/libavcodec/cfhd.c b/libavcodec/cfhd.c
index 0e6abe0..74facd4 100644
--- a/libavcodec/cfhd.c
+++ b/libavcodec/cfhd.c
@@ -438,6 +438,11 @@ static int cfhd_decode(AVCodecContext *avctx, void *data, int *got_frame,
                     return ret;
                 }
             }
+            ret = ff_set_dimensions(avctx, s->coded_width, s->coded_height);
+            if (ret < 0)
+                return ret;
+            frame.f->width =
+            frame.f->height = 0;
 
             if ((ret = ff_thread_get_buffer(avctx, &frame, 0)) < 0)
                 return ret;
-- 
1.7.9.5



More information about the ffmpeg-devel mailing list