Commit 67f9bbbb authored by Paul B Mahol's avatar Paul B Mahol

noise_bsf: check if allocation failed

Signed-off-by: 's avatarPaul B Mahol <onemda@gmail.com>
parent 8263726c
......@@ -36,6 +36,8 @@ static int noise(AVBitStreamFilterContext *bsfc, AVCodecContext *avctx, const ch
return AVERROR(EINVAL);
*poutbuf= av_malloc(buf_size + FF_INPUT_BUFFER_PADDING_SIZE);
if (!*poutbuf)
return AVERROR(ENOMEM);
memcpy(*poutbuf, buf, buf_size + FF_INPUT_BUFFER_PADDING_SIZE);
for(i=0; i<buf_size; i++){
......
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