mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-03-30 12:49:40 +00:00
aiffmux: avoid integer overflow
These values are 32 bits, and width is a multiple of 8. https://bugzilla.gnome.org/show_bug.cgi?id=654278
This commit is contained in:
parent
ffa9c81798
commit
fb2479d1da
1 changed files with 1 additions and 1 deletions
|
@ -236,7 +236,7 @@ gst_aiff_mux_write_comm_header (GstAiffMux * aiffmux, guint audio_data_size,
|
|||
gst_byte_writer_put_uint16_be (writer, aiffmux->channels);
|
||||
/* numSampleFrames value will be overwritten when known */
|
||||
gst_byte_writer_put_uint32_be (writer,
|
||||
(audio_data_size * 8) / (aiffmux->width * aiffmux->channels));
|
||||
audio_data_size / (aiffmux->width / 8 * aiffmux->channels));
|
||||
gst_byte_writer_put_uint16_be (writer, aiffmux->depth);
|
||||
gst_aiff_mux_write_ext (writer, aiffmux->rate);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue