mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-29 18:48:44 +00:00
ext/ffmpeg/gstffmpegcodecmap.c: Prevent likely segfault on EMPTY provided caps.
Original commit message from CVS: * ext/ffmpeg/gstffmpegcodecmap.c: (gst_ffmpeg_caps_with_codecid): Prevent likely segfault on EMPTY provided caps.
This commit is contained in:
parent
ffaf42c1df
commit
98c2db7ea6
3 changed files with 10 additions and 3 deletions
|
@ -1,3 +1,8 @@
|
|||
2008-07-11 Mark Nauwelaerts <mark.nauwelaerts@collabora.co.uk>
|
||||
|
||||
* ext/ffmpeg/gstffmpegcodecmap.c: (gst_ffmpeg_caps_with_codecid):
|
||||
Prevent likely segfault on EMPTY provided caps.
|
||||
|
||||
2008-07-06 Mark Nauwelaerts <mark.nauwelaerts@collabora.co.uk>
|
||||
|
||||
Based on a patch by: Aurelien Grimaud <gstelzz at yahoo dot fr>
|
||||
|
|
2
common
2
common
|
@ -1 +1 @@
|
|||
Subproject commit 593bb114c6f5c32b529aa6443be4c2d60d6484c7
|
||||
Subproject commit 79ade7b9c9bf47eee491ceee4cf3ea116140ad35
|
|
@ -1598,13 +1598,15 @@ void
|
|||
gst_ffmpeg_caps_with_codecid (enum CodecID codec_id,
|
||||
enum CodecType codec_type, const GstCaps * caps, AVCodecContext * context)
|
||||
{
|
||||
GstStructure *str = gst_caps_get_structure (caps, 0);
|
||||
GstStructure *str;
|
||||
const GValue *value;
|
||||
const GstBuffer *buf;
|
||||
|
||||
if (!context)
|
||||
if (!context || !gst_caps_get_size (caps))
|
||||
return;
|
||||
|
||||
str = gst_caps_get_structure (caps, 0);
|
||||
|
||||
/* extradata parsing (esds [mpeg4], wma/wmv, msmpeg4v1/2/3, etc.) */
|
||||
if ((value = gst_structure_get_value (str, "codec_data"))) {
|
||||
gint size;
|
||||
|
|
Loading…
Reference in a new issue