diff options
author | Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com> | 2016-11-13 22:59:47 +0100 |
---|---|---|
committer | Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com> | 2016-11-27 00:46:35 +0100 |
commit | 70ca4ce17a0a56118998afb81374d5b6d287182c (patch) | |
tree | 8d0adb0ebbb6cfd3517cfd86b369d3f2e3dc9dbe | |
parent | ccda73a711ba0d194e97fac476f9676183281ae7 (diff) | |
download | ffmpeg-70ca4ce17a0a56118998afb81374d5b6d287182c.tar.gz |
libschroedingerdec: don't produce empty frames
They are not valid and can cause problems/crashes for API users.
Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
(cherry picked from commit a86ebbf7f641bc797002ddea7fb517759722cd1b)
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
-rw-r--r-- | libavcodec/libschroedingerdec.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/libschroedingerdec.c b/libavcodec/libschroedingerdec.c index 6ddb811813..96f27313f0 100644 --- a/libavcodec/libschroedingerdec.c +++ b/libavcodec/libschroedingerdec.c @@ -307,7 +307,7 @@ static int libschroedinger_decode_frame(AVCodecContext *avctx, /* Grab next frame to be returned from the top of the queue. */ framewithpts = ff_schro_queue_pop(&p_schro_params->dec_frame_queue); - if (framewithpts && framewithpts->frame) { + if (framewithpts && framewithpts->frame && framewithpts->frame->components[0].stride) { int ret; if ((ret = ff_get_buffer(avctx, avframe, 0)) < 0) |