diff --git a/ffplay.c b/ffplay.c index e66dea1fcded4efa9758c256691d1a85ed987072..833b5b12cf43a5451838ffdb59444b76f4b22db9 100644 --- a/ffplay.c +++ b/ffplay.c @@ -991,7 +991,7 @@ static void video_audio_display(VideoState *s) av_free(s->rdft_data); s->rdft = av_rdft_init(rdft_bits, DFT_R2C); s->rdft_bits = rdft_bits; - s->rdft_data = av_malloc(4 * nb_freq * sizeof(*s->rdft_data)); + s->rdft_data = av_malloc_array(nb_freq, 4 *sizeof(*s->rdft_data)); } { FFTSample *data[2];