diff options
author | Alexandra Hájková <alexandra.khirnova@gmail.com> | 2015-09-02 14:27:42 +0200 |
---|---|---|
committer | Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com> | 2015-10-12 21:46:54 +0200 |
commit | f235f511a01c8c8f88c217e5ed4ec331d66521ac (patch) | |
tree | 8b0626cbac6f953d5ef738956324d5a0fb592aa9 | |
parent | c149a4afeef512222c8c8939386370cbbc0025c1 (diff) | |
download | ffmpeg-f235f511a01c8c8f88c217e5ed4ec331d66521ac.tar.gz |
asfdec: alloc enough space for storing name in asf_read_metadata_obj
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
(cherry picked from commit 77cf23668991bfd1fb69339f13e1511b4186b7b3)
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
-rw-r--r-- | libavformat/asfdec_o.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavformat/asfdec_o.c b/libavformat/asfdec_o.c index fa00813a81..db559f6c2b 100644 --- a/libavformat/asfdec_o.c +++ b/libavformat/asfdec_o.c @@ -583,7 +583,7 @@ static int asf_read_metadata_obj(AVFormatContext *s, const GUIDParseTable *g) break; type = avio_rl16(pb); val_len = avio_rl32(pb); - name = av_malloc(name_len); + name = av_malloc(buflen); if (!name) return AVERROR(ENOMEM); avio_get_str16le(pb, name_len, name, |