Commit 3a8b16f7 authored by Michael Niedermayer's avatar Michael Niedermayer

Merge commit '69277069'

* commit '69277069':
  dct: Check memory allocation

Conflicts:
	libavcodec/dct.c
Merged-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parents 7110b024 69277069
......@@ -191,6 +191,8 @@ av_cold int ff_dct_init(DCTContext *s, int nbits, enum DCTTransformType inverse)
s->costab = ff_cos_tabs[nbits + 2];
s->csc2 = av_malloc_array(n / 2, sizeof(FFTSample));
if (!s->csc2)
return AVERROR(ENOMEM);
if (ff_rdft_init(&s->rdft, nbits, inverse == DCT_III) < 0) {
av_freep(&s->csc2);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment