factory-uri: take ref to factory
authorWim Taymans <wim.taymans@collabora.co.uk>
Tue, 20 Nov 2012 11:10:16 +0000 (12:10 +0100)
committerWim Taymans <wim.taymans@collabora.co.uk>
Tue, 20 Nov 2012 11:10:16 +0000 (12:10 +0100)
Take a ref to the factory that we place in our list.

gst/rtsp-server/rtsp-media-factory-uri.c

index 733103c..ddcaf3f 100644 (file)
@@ -147,7 +147,7 @@ payloader_filter (GstPluginFeature * feature, FilterData * data)
 
   if (list) {
     GST_DEBUG ("adding %s", GST_OBJECT_NAME (fact));
-    *list = g_list_prepend (*list, fact);
+    *list = g_list_prepend (*list, gst_object_ref (fact));
   }
 
   return FALSE;