[FFmpeg-cvslog] avformat/riffde: Fix integer overflow in bitrate
Michael Niedermayer
git at videolan.org
Sun Jul 12 16:33:53 CEST 2015
ffmpeg | branch: master | Michael Niedermayer <michael at niedermayer.cc> | Sun Jul 12 16:24:20 2015 +0200| [839d6bc192f7ef94343872ff039799501af38855] | committer: Michael Niedermayer
avformat/riffde: Fix integer overflow in bitrate
Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=839d6bc192f7ef94343872ff039799501af38855
---
libavformat/riffdec.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/libavformat/riffdec.c b/libavformat/riffdec.c
index 3291d61..7eecdb2 100644
--- a/libavformat/riffdec.c
+++ b/libavformat/riffdec.c
@@ -99,13 +99,13 @@ int ff_get_wav_header(AVFormatContext *s, AVIOContext *pb,
id = avio_rl16(pb);
codec->channels = avio_rl16(pb);
codec->sample_rate = avio_rl32(pb);
- bitrate = avio_rl32(pb) * 8;
+ bitrate = avio_rl32(pb) * 8LL;
codec->block_align = avio_rl16(pb);
} else {
id = avio_rb16(pb);
codec->channels = avio_rb16(pb);
codec->sample_rate = avio_rb32(pb);
- bitrate = avio_rb32(pb) * 8;
+ bitrate = avio_rb32(pb) * 8LL;
codec->block_align = avio_rb16(pb);
}
if (size == 14) { /* We're dealing with plain vanilla WAVEFORMAT */
More information about the ffmpeg-cvslog
mailing list