summaryrefslogtreecommitdiff
path: root/libavcodec/libtheoraenc.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2015-03-12 21:38:47 +0100
committerMichael Niedermayer <michaelni@gmx.at>2015-03-12 21:41:55 +0100
commita91c175db20834d6474b104619505bcb537bf3f9 (patch)
tree0ad814709cffa98fed8627f565755423f0a1a554 /libavcodec/libtheoraenc.c
parent9ecfe0b87834576ce69401067fe1130a723eb2d4 (diff)
parent17c45d4d056d0e10ecb88b424ec9e68be398da5e (diff)
Merge commit '17c45d4d056d0e10ecb88b424ec9e68be398da5e'
* commit '17c45d4d056d0e10ecb88b424ec9e68be398da5e': libtheora: Check frame allocation Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/libtheoraenc.c')
-rw-r--r--libavcodec/libtheoraenc.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/libavcodec/libtheoraenc.c b/libavcodec/libtheoraenc.c
index b4b395aa8c..9366a95e30 100644
--- a/libavcodec/libtheoraenc.c
+++ b/libavcodec/libtheoraenc.c
@@ -267,6 +267,8 @@ static av_cold int encode_init(AVCodecContext* avc_context)
/* Set up the output AVFrame */
avc_context->coded_frame = av_frame_alloc();
+ if (!avc_context->coded_frame)
+ return AVERROR(ENOMEM);
return 0;
}