mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-04-26 06:54:49 +00:00
gst/qtdemux/qtdemux.c: Don't crash on twos/sowt/raw audio. #345830.
Original commit message from CVS: * gst/qtdemux/qtdemux.c: (qtdemux_parse_trak): Don't crash on twos/sowt/raw audio. #345830.
This commit is contained in:
parent
4af71bd569
commit
2c601a7a19
2 changed files with 13 additions and 4 deletions
|
@ -1,3 +1,8 @@
|
||||||
|
2006-07-07 Wim Taymans <wim@fluendo.com>
|
||||||
|
|
||||||
|
* gst/qtdemux/qtdemux.c: (qtdemux_parse_trak):
|
||||||
|
Don't crash on twos/sowt/raw audio. #345830.
|
||||||
|
|
||||||
2006-07-07 Wim Taymans <wim@fluendo.com>
|
2006-07-07 Wim Taymans <wim@fluendo.com>
|
||||||
|
|
||||||
Patch by: Lutz Mueller <lutz at topfrose dot de>
|
Patch by: Lutz Mueller <lutz at topfrose dot de>
|
||||||
|
|
|
@ -3256,10 +3256,14 @@ qtdemux_parse_trak (GstQTDemux * qtdemux, GNode * trak)
|
||||||
GST_LOG ("bytes/frame: %d", stream->bytes_per_frame);
|
GST_LOG ("bytes/frame: %d", stream->bytes_per_frame);
|
||||||
GST_LOG ("bytes/sample: %d", stream->bytes_per_sample);
|
GST_LOG ("bytes/sample: %d", stream->bytes_per_sample);
|
||||||
|
|
||||||
if (!stream->sampled) {
|
if (fourcc != GST_MAKE_FOURCC ('t', 'w', 'o', 's') &&
|
||||||
stream->samples_per_frame = (stream->bytes_per_frame /
|
fourcc != GST_MAKE_FOURCC ('s', 'o', 'w', 't') &&
|
||||||
stream->bytes_per_packet) * stream->samples_per_packet;
|
fourcc != GST_MAKE_FOURCC ('r', 'a', 'w', ' ')) {
|
||||||
GST_LOG ("samples/frame: %d", stream->samples_per_frame);
|
if (!stream->sampled) {
|
||||||
|
stream->samples_per_frame = (stream->bytes_per_frame /
|
||||||
|
stream->bytes_per_packet) * stream->samples_per_packet;
|
||||||
|
GST_LOG ("samples/frame: %d", stream->samples_per_frame);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
offset = 68;
|
offset = 68;
|
||||||
} else if (version == 0x00020000) {
|
} else if (version == 0x00020000) {
|
||||||
|
|
Loading…
Reference in a new issue