Merge remote-tracking branch 'upstream/master' into tizen
[platform/upstream/gstreamer.git] / gst / gstpadtemplate.c
index a066de7..8055a9a 100644 (file)
@@ -42,7 +42,7 @@
  * GST_PAD_TEMPLATE_DIRECTION().
  *
  * The GST_PAD_TEMPLATE_NAME_TEMPLATE () is important for GST_PAD_REQUEST pads
- * because it has to be used as the name in the gst_element_get_request_pad()
+ * because it has to be used as the name in the gst_element_request_pad_simple()
  * call to instantiate a pad from this template.
  *
  * Padtemplates can be created with gst_pad_template_new() or with
@@ -483,7 +483,7 @@ gst_pad_template_get_caps (GstPadTemplate * templ)
 /**
  * gst_pad_template_set_documentation_caps:
  * @templ: the pad template to set documented capabilities on
- * @caps: the documented capabilities
+ * @caps: (transfer full): the documented capabilities
  *
  * Certain elements will dynamically construct the caps of their
  * pad templates. In order not to let environment-specific information
@@ -498,6 +498,8 @@ gst_pad_template_set_documentation_caps (GstPadTemplate * templ, GstCaps * caps)
   g_return_if_fail (GST_IS_PAD_TEMPLATE (templ));
   g_return_if_fail (GST_IS_CAPS (caps));
 
+  if (caps)
+    GST_MINI_OBJECT_FLAG_SET (caps, GST_MINI_OBJECT_FLAG_MAY_BE_LEAKED);
   gst_caps_replace (&(((GstPadTemplate *) (templ))->ABI.abi.documentation_caps),
       caps);
 }