elementfactory: fix caps leak in element factory list utility functions
authorTim-Philipp Müller <tim.muller@collabora.co.uk>
Thu, 18 Nov 2010 00:29:19 +0000 (00:29 +0000)
committerTim-Philipp Müller <tim.muller@collabora.co.uk>
Thu, 18 Nov 2010 00:29:19 +0000 (00:29 +0000)
gst/gstelementfactory.c

index 903e812..de9fb6b 100644 (file)
@@ -906,6 +906,7 @@ gst_element_factory_list_filter (GList * list,
             (!subsetonly && gst_caps_can_intersect (caps, tmpl_caps))) {
           /* non empty intersection, we can use this element */
           result = g_list_prepend (result, gst_object_ref (factory));
+          gst_caps_unref (tmpl_caps);
           break;
         }
         gst_caps_unref (tmpl_caps);