[vala/0.14] gstreamer-0.10: Fix several ownership transfer when adding children



commit cd66e7a9cce393187d0232524053b5b11d02a117
Author: Jens Georg <mail jensge org>
Date:   Fri Dec 16 13:33:29 2011 +0100

    gstreamer-0.10: Fix several ownership transfer when adding children
    
    gst_bin_add, gst_bin_add_many and gst_element_add_pad only transfer
    ownership if the reference is floating, otherwise increasing the
    refcount. The reference is added by gst_object_set_parent.
    
    Fixes bug 666358.

 vapi/gstreamer-0.10.vapi                           |    6 +++---
 .../gstreamer-0.10/gstreamer-0.10-custom.vala      |    2 +-
 .../gstreamer-0.10/gstreamer-0.10.metadata         |    2 --
 3 files changed, 4 insertions(+), 6 deletions(-)
---
diff --git a/vapi/gstreamer-0.10.vapi b/vapi/gstreamer-0.10.vapi
index e083a9f..554aa5a 100644
--- a/vapi/gstreamer-0.10.vapi
+++ b/vapi/gstreamer-0.10.vapi
@@ -43,10 +43,10 @@ namespace Gst {
 		public bool state_dirty;
 		[CCode (has_construct_function = false, type = "GstElement*")]
 		public Bin (string? name);
-		public bool add (owned Gst.Element element);
+		public bool add (Gst.Element element);
 		[NoWrapper]
 		public virtual bool add_element (Gst.Element element);
-		public void add_many (params owned Gst.Element[] elements);
+		public void add_many (params Gst.Element[] elements);
 		public Gst.Pad? find_unconnected_pad (Gst.PadDirection direction);
 		public Gst.Pad? find_unlinked_pad (Gst.PadDirection direction);
 		public Gst.Element? get_by_interface (GLib.Type iface);
@@ -411,7 +411,7 @@ namespace Gst {
 		[CCode (has_construct_function = false)]
 		protected Element ();
 		public void abort_state ();
-		public bool add_pad (owned Gst.Pad pad);
+		public bool add_pad (Gst.Pad pad);
 		[CCode (cname = "gst_element_class_add_pad_template")]
 		public class void add_pad_template (Gst.PadTemplate templ);
 		public virtual Gst.StateChangeReturn change_state (Gst.StateChange transition);
diff --git a/vapi/packages/gstreamer-0.10/gstreamer-0.10-custom.vala b/vapi/packages/gstreamer-0.10/gstreamer-0.10-custom.vala
index dc85a05..f99d1e4 100644
--- a/vapi/packages/gstreamer-0.10/gstreamer-0.10-custom.vala
+++ b/vapi/packages/gstreamer-0.10/gstreamer-0.10-custom.vala
@@ -148,7 +148,7 @@ namespace Gst {
 	}
 
 	public class Bin {
-		public void add_many (params owned Gst.Element[] elements);
+		public void add_many (params Gst.Element[] elements);
 		public void remove_many (params Gst.Element[] elements);
 	}
 
diff --git a/vapi/packages/gstreamer-0.10/gstreamer-0.10.metadata b/vapi/packages/gstreamer-0.10/gstreamer-0.10.metadata
index 264fd3e..81015a0 100644
--- a/vapi/packages/gstreamer-0.10/gstreamer-0.10.metadata
+++ b/vapi/packages/gstreamer-0.10/gstreamer-0.10.metadata
@@ -5,7 +5,6 @@ GstBin.priv hidden="1"
 GstBin.children type_arguments="Element"
 GstBin.messages type_arguments="Message"
 gst_bin_new.name nullable="1"
-gst_bin_add.element value_owned="1"
 gst_bin_remove.element
 gst_bin_add_many hidden="1"
 gst_bin_remove_many hidden="1"
@@ -122,7 +121,6 @@ GstElement.sinkpads type_arguments="Pad"
 GstElement.srcpads type_arguments="Pad"
 GstElement.abidata hidden="1"
 GstElementClass hidden="1"
-gst_element_add_pad.pad takes_ownership="1"
 gst_element_link_many ellipsis="1"
 gst_element_unlink_many ellipsis="1"
 gst_element_found_tags.list takes_ownership="1"



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]