You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-08-15 14:13:16 +02:00
avformat/rmdec: zero string destination before use
Fixes use of uninitialized memory Fixes: msan_uninit-mem_7f9677850d99_4635_crashed.rm Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
@@ -185,6 +185,7 @@ static int rm_read_audio_stream_info(AVFormatContext *s, AVIOContext *pb,
|
|||||||
avio_read(pb, buf, 4);
|
avio_read(pb, buf, 4);
|
||||||
buf[4] = 0;
|
buf[4] = 0;
|
||||||
} else {
|
} else {
|
||||||
|
AV_WL32(buf, 0);
|
||||||
get_str8(pb, buf, sizeof(buf)); /* desc */
|
get_str8(pb, buf, sizeof(buf)); /* desc */
|
||||||
ast->deint_id = AV_RL32(buf);
|
ast->deint_id = AV_RL32(buf);
|
||||||
get_str8(pb, buf, sizeof(buf)); /* desc */
|
get_str8(pb, buf, sizeof(buf)); /* desc */
|
||||||
|
Reference in New Issue
Block a user