mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-02-20 21:16:24 +00:00
typefind: Fix previous commit
We need to make sure we have *enough* data to read (including the next 4 bytes)
This commit is contained in:
parent
b1c135aa72
commit
32eae2b166
1 changed files with 1 additions and 1 deletions
|
@ -3146,7 +3146,7 @@ q3gp_type_find (GstTypeFind * tf, gpointer unused)
|
|||
ftyp_size = GST_READ_UINT32_BE (data);
|
||||
}
|
||||
if ((data = gst_type_find_peek (tf, 0, ftyp_size)) != NULL) {
|
||||
for (offset = 16; offset < ftyp_size; offset += 4) {
|
||||
for (offset = 16; offset + 4 < ftyp_size; offset += 4) {
|
||||
if ((profile = q3gp_type_find_get_profile (data + offset))) {
|
||||
gst_type_find_suggest_simple (tf, GST_TYPE_FIND_MAXIMUM,
|
||||
"application/x-3gp", "profile", G_TYPE_STRING, profile, NULL);
|
||||
|
|
Loading…
Reference in a new issue