[FFmpeg-devel] [PATCH 1/2] ffplay: use av_malloc_array()

Michael Niedermayer michaelni at gmx.at
Tue Aug 26 00:13:02 CEST 2014


On Mon, Aug 25, 2014 at 11:51:58PM +0200, Marton Balint wrote:
> 
> On Mon, 25 Aug 2014, Michael Niedermayer wrote:
> 
> >Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
> >---
> >ffplay.c |    2 +-
> >1 file changed, 1 insertion(+), 1 deletion(-)
> >
> >diff --git a/ffplay.c b/ffplay.c
> >index e66dea1..833b5b1 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));
> 
> LGTM, thanks.

applied

thanks

[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Into a blind darkness they enter who follow after the Ignorance,
they as if into a greater darkness enter who devote themselves
to the Knowledge alone. -- Isha Upanishad
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 181 bytes
Desc: Digital signature
URL: <https://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20140826/4fdcefd5/attachment.asc>


More information about the ffmpeg-devel mailing list