aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLuca Barbato <lu_zero@gentoo.org>2015-11-01 04:07:46 +0100
committerLuca Barbato <lu_zero@gentoo.org>2015-11-02 16:28:31 +0100
commit4a326923381f2bc0fb7d960c8f8366a5456bc4ab (patch)
treeb4b4896415ee23ed60635353e09b4cd690d0734d
parent452d659aa4a742106c70ffe9ef3df47ef5b81ea6 (diff)
downloadffmpeg-4a326923381f2bc0fb7d960c8f8366a5456bc4ab.tar.gz
mimic: Always return on failure
Bug-Id: 905 CC: libav-stable@libav.org Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
-rw-r--r--libavcodec/mimic.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/libavcodec/mimic.c b/libavcodec/mimic.c
index 379cffc27e..b8b3285050 100644
--- a/libavcodec/mimic.c
+++ b/libavcodec/mimic.c
@@ -431,10 +431,9 @@ static int mimic_decode_frame(AVCodecContext *avctx, void *data,
res = decode(ctx, quality, num_coeffs, !is_pframe);
ff_thread_report_progress(&ctx->frames[ctx->cur_index], INT_MAX, 0);
if (res < 0) {
- if (!(avctx->active_thread_type & FF_THREAD_FRAME)) {
+ if (!(avctx->active_thread_type & FF_THREAD_FRAME))
ff_thread_release_buffer(avctx, &ctx->frames[ctx->cur_index]);
- return res;
- }
+ return res;
}
if ((res = av_frame_ref(data, ctx->frames[ctx->cur_index].f)) < 0)