summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libavformat/oggparsetheora.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/libavformat/oggparsetheora.c b/libavformat/oggparsetheora.c
index 3d5785b74c..961096edaa 100644
--- a/libavformat/oggparsetheora.c
+++ b/libavformat/oggparsetheora.c
@@ -50,6 +50,8 @@ static int theora_header(AVFormatContext *s, int idx)
if (!thp) {
thp = av_mallocz(sizeof(*thp));
+ if (!thp)
+ return AVERROR(ENOMEM);
os->private = thp;
}