mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-18 14:26:43 +00:00
matroskademux: Skip over zero-sized Xiph stream headers
Thanks to Antonio Morales for finding and reporting the issue. Fixes GHSL-2024-251 Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/3867 Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8057>
This commit is contained in:
parent
c20eff779d
commit
b84a0f3263
1 changed files with 4 additions and 2 deletions
|
@ -189,8 +189,10 @@ gst_matroska_parse_xiph_stream_headers (gpointer codec_data,
|
|||
if (offset + length[i] > codec_data_size)
|
||||
goto error;
|
||||
|
||||
hdr = gst_buffer_new_memdup (p + offset, length[i]);
|
||||
gst_buffer_list_add (list, hdr);
|
||||
if (length[i] > 0) {
|
||||
hdr = gst_buffer_new_memdup (p + offset, length[i]);
|
||||
gst_buffer_list_add (list, hdr);
|
||||
}
|
||||
|
||||
offset += length[i];
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue