mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-23 10:11:08 +00:00
aacparse: ensure sufficient data available before accessing
This commit is contained in:
parent
f3d2429f92
commit
7cd3f0a2db
1 changed files with 3 additions and 0 deletions
|
@ -342,6 +342,9 @@ gst_aacparse_check_adts_frame (GstAacParse * aacparse,
|
|||
const guint8 * data,
|
||||
const guint avail, guint * framesize, guint * needed_data)
|
||||
{
|
||||
if (G_UNLIKELY (avail < 2))
|
||||
return FALSE;
|
||||
|
||||
if ((data[0] == 0xff) && ((data[1] & 0xf6) == 0xf0)) {
|
||||
*framesize = gst_aacparse_adts_get_frame_len (data);
|
||||
|
||||
|
|
Loading…
Reference in a new issue