[Gstreamer-bugs] [Bug 134839] Changed - buffers leaked by filesrc, typefind, spider or fakesink

bugzilla-daemon at widget.gnome.org bugzilla-daemon at widget.gnome.org
Wed Mar 10 07:50:22 PST 2004


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

http://bugzilla.gnome.org/show_bug.cgi?id=134839

Changed by t.i.m at zen.co.uk.

--- shadow/134839	Tue Mar  9 15:38:08 2004
+++ shadow/134839.tmp.29383	Wed Mar 10 10:50:21 2004
@@ -80,6 +80,56 @@
  
 As far as I can see, it leaks less than before, but still leaks 
 massively, with CVS HEAD from 2004-March-09. 
  
  
  
+
+------- Additional Comments From t.i.m at zen.co.uk  2004-03-10 10:50 -------
+Some more information: 
+ 
+I think the 'mad' element that is created when running the  
+ 
+        filesrc ! typefind ! spider ! fakesink 
+ 
+pipeline on an mp3 file is never disposed of when the pipeline gets 
+destroyed. 
+ 
+Here's what I did to come to that conclusion: 
+ 
+static gpointer maddata;  /* NULL */ 
+static gpointer pipedata; /* NULL */ 
+ 
+static void 
+ea_cb (GstBin *spider, GstElement *element, gpointer foo) 
+{ 
+  g_print("ELEMENT ADDED: %s\n", gst_element_get_name(element)); 
+  if (strncmp(gst_element_get_name(element), "mad", 3) == 0) 
+  { 
+    g_print ("hooking up nullifier...\n"); 
+    maddata = spider; 
+    g_object_set_data_full(G_OBJECT(element), "madfoo", &maddata, 
+(GDestroyNotify)g_nullify_pointer); 
+  } 
+} 
+ 
+..... 
+ 
+g_signal_connect(spider, "element-added", ea_cb, NULL); 
+ 
+gobject_set_data_full(G_OBJECT(pipeline), "pipefoo", &pipedata, 
+(GDestroyNotify)g_nullify_pointer); 
+ 
+...... 
+ 
+after the pipeline is unrefed, pipedata will be NULL, but maddata 
+will still be some non-NULL value, so the mad object didn't get 
+destroyed. 
+ 
+I am not sure if that would cause huge leaks like that, but it's 
+worth a shot. 
+ 
+Hope this helps whoever is debugging this further :) 
+ 
+Cheers 
+-Tim 
+ 




More information about the Gstreamer-bugs mailing list