mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-03-30 12:49:40 +00:00
gdkpixbuf: don't leak template caps
This commit is contained in:
parent
899d03dcc6
commit
226deb9b38
1 changed files with 4 additions and 2 deletions
|
@ -118,6 +118,7 @@ gst_gdk_pixbuf_get_capslist (void)
|
|||
GSList *slist0;
|
||||
GstCaps *capslist = NULL;
|
||||
GstCaps *return_caps = NULL;
|
||||
GstCaps *tmpl_caps;
|
||||
|
||||
capslist = gst_caps_new_empty ();
|
||||
slist0 = gdk_pixbuf_get_formats ();
|
||||
|
@ -137,9 +138,10 @@ gst_gdk_pixbuf_get_capslist (void)
|
|||
}
|
||||
g_slist_free (slist0);
|
||||
|
||||
return_caps = gst_caps_intersect (capslist,
|
||||
gst_static_caps_get (&gst_gdk_pixbuf_sink_template.static_caps));
|
||||
tmpl_caps = gst_static_caps_get (&gst_gdk_pixbuf_sink_template.static_caps);
|
||||
return_caps = gst_caps_intersect (capslist, tmpl_caps);
|
||||
|
||||
gst_caps_unref (tmpl_caps);
|
||||
gst_caps_unref (capslist);
|
||||
return return_caps;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue