[FFmpeg-cvslog] r9833 - trunk/libavcodec/atrac3.c
takis
subversion
Mon Jul 30 15:58:18 CEST 2007
Author: takis
Date: Mon Jul 30 15:58:17 2007
New Revision: 9833
Log:
Handle malloc failure
Modified:
trunk/libavcodec/atrac3.c
Modified: trunk/libavcodec/atrac3.c
==============================================================================
--- trunk/libavcodec/atrac3.c (original)
+++ trunk/libavcodec/atrac3.c Mon Jul 30 15:58:17 2007
@@ -1047,6 +1047,10 @@ static int atrac3_decode_init(AVCodecCon
dsputil_init(&dsp, avctx);
q->pUnits = av_mallocz(sizeof(channel_unit)*q->channels);
+ if (!q->pUnits) {
+ av_free(q->decoded_bytes_buffer);
+ return AVERROR(ENOMEM);
+ }
return 0;
}
More information about the ffmpeg-cvslog
mailing list