summaryrefslogtreecommitdiff
path: root/libavformat/oggenc.c
diff options
context:
space:
mode:
Diffstat (limited to 'libavformat/oggenc.c')
-rw-r--r--libavformat/oggenc.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/libavformat/oggenc.c b/libavformat/oggenc.c
index 70c7817fa8..8f8a08f1bd 100644
--- a/libavformat/oggenc.c
+++ b/libavformat/oggenc.c
@@ -444,6 +444,8 @@ static int ogg_write_header(AVFormatContext *s)
return -1;
}
oggstream = av_mallocz(sizeof(*oggstream));
+ if (!oggstream)
+ return AVERROR(ENOMEM);
oggstream->page.stream_index = i;
if (!(s->flags & AVFMT_FLAG_BITEXACT))