diff options
author | David Schleef <ds@schleef.org> | 2003-07-24 08:49:42 +0000 |
---|---|---|
committer | David Schleef <ds@schleef.org> | 2003-07-24 08:49:42 +0000 |
commit | 322baf19c80857f1f2b016ec6bf043d09c67d154 (patch) | |
tree | 188aeeb96adf54022f3884d9e3a731765e7bd70e /gst/auparse | |
parent | 7bea2b377a4bb138b26ef7b07a466380ae7e13b0 (diff) |
Add buffer length checks to every typefinding function
Original commit message from CVS:
Add buffer length checks to every typefinding function
Diffstat (limited to 'gst/auparse')
-rw-r--r-- | gst/auparse/gstauparse.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/gst/auparse/gstauparse.c b/gst/auparse/gstauparse.c index 82f802f1..9942fd7b 100644 --- a/gst/auparse/gstauparse.c +++ b/gst/auparse/gstauparse.c @@ -47,6 +47,9 @@ au_type_find (GstBuffer *buf, gpointer private) GstCaps *new = NULL; gulong *head = (gulong *) GST_BUFFER_DATA (buf); + if (GST_BUFFER_SIZE (buf) < 4) + return NULL; + if (*head == 0x2e736e64 || *head == 0x646e732e) new = gst_caps_new ("au_type_find", "audio/au", NULL); |