diff --git a/libavcodec/diracdec.c b/libavcodec/diracdec.c index b183fad584..5c669ffdee 100644 --- a/libavcodec/diracdec.c +++ b/libavcodec/diracdec.c @@ -907,7 +907,7 @@ static int decode_lowdelay(DiracContext *s) int slice_num = 0; if (s->slice_params_num_buf != (s->num_x * s->num_y)) { - s->slice_params_buf = av_realloc_f(s->thread_buf, s->num_x * s->num_y, sizeof(DiracSlice)); + s->slice_params_buf = av_realloc_f(s->slice_params_buf, s->num_x * s->num_y, sizeof(DiracSlice)); if (!s->slice_params_buf) { av_log(s->avctx, AV_LOG_ERROR, "slice params buffer allocation failure\n"); return AVERROR(ENOMEM);