mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-09 17:05:52 +00:00
gst/autoplug/gstspider.c: fixed caps leak
Original commit message from CVS: 2004-03-06 Christophe Fergeau <teuf@gnome.org> * gst/autoplug/gstspider.c: (gst_spider_identity_plug): fixed caps leak
This commit is contained in:
parent
c27e70d3c1
commit
91e0700148
2 changed files with 11 additions and 3 deletions
|
@ -1,3 +1,8 @@
|
||||||
|
2004-03-06 Christophe Fergeau <teuf@gnome.org>
|
||||||
|
|
||||||
|
* gst/autoplug/gstspider.c: (gst_spider_identity_plug): fixed caps
|
||||||
|
leak
|
||||||
|
|
||||||
2004-03-05 David Schleef <ds@schleef.org>
|
2004-03-05 David Schleef <ds@schleef.org>
|
||||||
|
|
||||||
reviewed by: <delete if not using a buddy>
|
reviewed by: <delete if not using a buddy>
|
||||||
|
|
|
@ -394,13 +394,10 @@ gst_spider_identity_plug (GstSpiderIdentity *ident)
|
||||||
GstCaps *src_caps = gst_pad_get_caps (ident->src);
|
GstCaps *src_caps = gst_pad_get_caps (ident->src);
|
||||||
if (! gst_caps_is_empty (src_caps) && ! gst_caps_is_any (src_caps))
|
if (! gst_caps_is_empty (src_caps) && ! gst_caps_is_any (src_caps))
|
||||||
{
|
{
|
||||||
const char *mime;
|
|
||||||
GList *factories;
|
GList *factories;
|
||||||
GstPadTemplate *padtemp;
|
GstPadTemplate *padtemp;
|
||||||
gboolean found = FALSE;
|
gboolean found = FALSE;
|
||||||
|
|
||||||
mime = gst_structure_get_name (gst_caps_get_structure (src_caps, 0));
|
|
||||||
|
|
||||||
factories = spider->factories;
|
factories = spider->factories;
|
||||||
while (factories)
|
while (factories)
|
||||||
{
|
{
|
||||||
|
@ -414,12 +411,18 @@ gst_spider_identity_plug (GstSpiderIdentity *ident)
|
||||||
}
|
}
|
||||||
if (!found)
|
if (!found)
|
||||||
{
|
{
|
||||||
|
const char *mime;
|
||||||
|
|
||||||
|
mime = gst_structure_get_name (gst_caps_get_structure (src_caps, 0));
|
||||||
|
|
||||||
GST_ELEMENT_ERROR (spider, STREAM, CODEC_NOT_FOUND,
|
GST_ELEMENT_ERROR (spider, STREAM, CODEC_NOT_FOUND,
|
||||||
(_("There is no element present to handle the stream's mime type %s."), mime),
|
(_("There is no element present to handle the stream's mime type %s."), mime),
|
||||||
(NULL));
|
(NULL));
|
||||||
|
gst_caps_free (src_caps);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
gst_caps_free (src_caps);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue