diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2015-05-10 19:54:41 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2015-05-10 20:03:36 +0200 |
commit | 004564c930ef60d2f9e8798e820ed7b2a37ba0bd (patch) | |
tree | 9f918bbecd27065dc63da9634c7ae122e4e98556 | |
parent | ecb4ae7879fd51d4f1828f386908b744010da7ae (diff) | |
download | ffmpeg-004564c930ef60d2f9e8798e820ed7b2a37ba0bd.tar.gz |
avformat/wavenc: Check umid length
Fixes potential out of array read
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r-- | libavformat/wavenc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavformat/wavenc.c b/libavformat/wavenc.c index baadd9149b..74b5d56f84 100644 --- a/libavformat/wavenc.c +++ b/libavformat/wavenc.c @@ -120,7 +120,7 @@ static void bwf_write_bext_chunk(AVFormatContext *s) avio_wl64(s->pb, time_reference); avio_wl16(s->pb, 1); // set version to 1 - if (tmp_tag = av_dict_get(s->metadata, "umid", NULL, 0)) { + if ((tmp_tag = av_dict_get(s->metadata, "umid", NULL, 0)) && strlen(tmp_tag->value) > 2) { unsigned char umidpart_str[17] = {0}; int64_t i; uint64_t umidpart; |