[FFmpeg-cvslog] adpcmenc: check for coded_frame allocation failure
Justin Ruggles
git at videolan.org
Wed Feb 1 03:06:30 CET 2012
ffmpeg | branch: master | Justin Ruggles <justin.ruggles at gmail.com> | Mon Jan 30 13:03:01 2012 -0500| [cb023d9afe9da0a9d221b5eeddd2981c520b5978] | committer: Justin Ruggles
adpcmenc: check for coded_frame allocation failure
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=cb023d9afe9da0a9d221b5eeddd2981c520b5978
---
libavcodec/adpcmenc.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/libavcodec/adpcmenc.c b/libavcodec/adpcmenc.c
index 9cf1e391..26d673d 100644
--- a/libavcodec/adpcmenc.c
+++ b/libavcodec/adpcmenc.c
@@ -135,7 +135,8 @@ static av_cold int adpcm_encode_init(AVCodecContext *avctx)
goto error;
}
- avctx->coded_frame = avcodec_alloc_frame();
+ if (!(avctx->coded_frame = avcodec_alloc_frame()))
+ goto error;
return 0;
error:
More information about the ffmpeg-cvslog
mailing list