aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat/dv.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2015-01-23 18:15:43 +0100
committerMichael Niedermayer <michaelni@gmx.at>2015-01-23 18:15:43 +0100
commit72d99c8c2647c77e01dfc82a354d500d48258469 (patch)
tree7842cb0acb293fc50399f70093eb79379f8ce223 /libavformat/dv.c
parentd36e66bb2622d15e53d0a02a4685a8345cf93d7d (diff)
downloadffmpeg-72d99c8c2647c77e01dfc82a354d500d48258469.tar.gz
avformat/dv: check av_malloc() return code
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavformat/dv.c')
-rw-r--r--libavformat/dv.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/libavformat/dv.c b/libavformat/dv.c
index 0a893f482e..3243ca2ece 100644
--- a/libavformat/dv.c
+++ b/libavformat/dv.c
@@ -472,6 +472,9 @@ static int dv_read_timecode(AVFormatContext *s) {
partial_frame_size);
RawDVContext *c = s->priv_data;
+ if (!partial_frame)
+ return AVERROR(ENOMEM);
+
ret = avio_read(s->pb, partial_frame, partial_frame_size);
if (ret < 0)
goto finish;