diff --git a/gst/check/gstcheck.c b/gst/check/gstcheck.c
index f1c05a0570..54093bf21d 100644
--- a/gst/check/gstcheck.c
+++ b/gst/check/gstcheck.c
@@ -168,7 +168,8 @@ gst_check_setup_src_pad (GstElement * element,
fail_if (sinkpad == NULL, "Could not get sink pad from %s",
GST_ELEMENT_NAME (element));
ASSERT_OBJECT_REFCOUNT (sinkpad, "sinkpad", 2);
- fail_unless (gst_pad_set_caps (srcpad, caps));
+ if (caps)
+ fail_unless (gst_pad_set_caps (srcpad, caps));
fail_unless (gst_pad_link (srcpad, sinkpad) == GST_PAD_LINK_OK,
"Could not link source and %s sink pads", GST_ELEMENT_NAME (element));
gst_object_unref (sinkpad); /* because we got it higher up */
@@ -218,7 +219,8 @@ gst_check_setup_sink_pad (GstElement * element, GstStaticPadTemplate * template,
srcpad = gst_element_get_pad (element, "src");
fail_if (srcpad == NULL, "Could not get source pad from %s",
GST_ELEMENT_NAME (element));
- fail_unless (gst_pad_set_caps (sinkpad, caps));
+ if (caps)
+ fail_unless (gst_pad_set_caps (sinkpad, caps));
gst_pad_set_chain_function (sinkpad, gst_check_chain_func);
fail_unless (gst_pad_link (srcpad, sinkpad) == GST_PAD_LINK_OK,
diff --git a/gst/gst.c b/gst/gst.c
index ea9ee3966a..abbeacdf62 100644
--- a/gst/gst.c
+++ b/gst/gst.c
@@ -69,7 +69,6 @@
*
* static gboolean stats = FALSE;
* ...
- *
* int
* main (int argc, char *argv[])
* {
@@ -78,10 +77,8 @@
* "Show pad stats", NULL},
* POPT_TABLEEND
* };
- *
* // initialize the GStreamer library
* gst_init_with_popt_table (&argc, &argv, options);
- *
* ...
* }
*
diff --git a/gst/gstbuffer.c b/gst/gstbuffer.c
index 6be177eb1f..a59a75ed8d 100644
--- a/gst/gstbuffer.c
+++ b/gst/gstbuffer.c
@@ -40,11 +40,8 @@
*
* GstBuffer *buffer;
* gint size, width, height, bpp;
- *
* ...
- *
* size = width * height * bpp;
- *
* buffer = gst_buffer_new ();
* GST_BUFFER_SIZE (buffer) = size;
* GST_BUFFER_MALLOCDATA (buffer) = g_alloc (size);
diff --git a/gst/gstcaps.c b/gst/gstcaps.c
index ef31954f7b..f0fc00bc25 100644
--- a/gst/gstcaps.c
+++ b/gst/gstcaps.c
@@ -33,7 +33,7 @@
#include "gst_private.h"
#include
-/* #define DEBUG_REFCOUNT */
+#define DEBUG_REFCOUNT
#define CAPS_POISON(caps) G_STMT_START{ \
if (caps) { \
diff --git a/gst/gstelementfactory.c b/gst/gstelementfactory.c
index dc99d23600..fa85bc1679 100644
--- a/gst/gstelementfactory.c
+++ b/gst/gstelementfactory.c
@@ -47,15 +47,11 @@
* Using an element factory
*
* #include <gst/gst.h>
- *
* GstElement *src;
* GstElementFactory *srcfactory;
- *
* gst_init(&argc,&argv);
- *
* srcfactory = gst_element_factory_find("filesrc");
* g_return_if_fail(srcfactory != NULL);
- *
* src = gst_element_factory_create(srcfactory,"src");
* g_return_if_fail(src != NULL);
* ...
diff --git a/gst/gstpadtemplate.c b/gst/gstpadtemplate.c
index 930bab76d0..b96688a214 100644
--- a/gst/gstpadtemplate.c
+++ b/gst/gstpadtemplate.c
@@ -51,12 +51,10 @@
* "channels = (int) [ 1, 6 ]"
* )
* )
- *
* void
* my_method (void)
* {
* GstPad *pad;
- *
* pad = gst_pad_new_from_template (GST_PAD_TEMPLATE_GET (my_template_factory), "sink");
* ...
* }
@@ -71,14 +69,10 @@
* my_factory_init (GstPlugin *plugin)
* {
* GstElementFactory *factory;
- *
* factory = gst_element_factory_new ("my_factory", GST_TYPE_MYFACTORY, &gst_myfactory_details);
* g_return_val_if_fail (factory != NULL, FALSE);
- *
* gst_element_factory_add_pad_template (factory, GST_PAD_TEMPLATE_GET (my_template_factory));
- *
* gst_plugin_add_feature (plugin, GST_PLUGIN_FEATURE (factory));
- *
* return TRUE;
* }
*
diff --git a/gst/gstplugin.c b/gst/gstplugin.c
index b72d2387ad..7003a078fb 100644
--- a/gst/gstplugin.c
+++ b/gst/gstplugin.c
@@ -29,7 +29,8 @@
* A plugin system can provide one or more of the basic
* GStreamer #GstPluginFeature subclasses.
*
- * A plugin should export a symbol plugin_desc that is a struct of type #GstPluginDesc.
+ * A plugin should export a symbol plugin_desc that is a
+ * struct of type #GstPluginDesc.
* the plugin loader will check the version of the core library the plugin was
* linked against and will create a new #GstPlugin. It will then call the
* #GstPluginInitFunc function that was provided in the plugin_desc.
@@ -889,7 +890,6 @@ gst_plugin_load_by_name (const gchar * name)
*
* GstPlugin *loaded_plugin;
* loaded_plugin = gst_plugin_load (plugin);
- *
* // presumably, we're no longer interested in the potentially-unloaded plugin
* gst_object_unref (plugin);
* plugin = loaded_plugin;
diff --git a/gst/gsttypefindfactory.c b/gst/gsttypefindfactory.c
index 993f393850..48b014577c 100644
--- a/gst/gsttypefindfactory.c
+++ b/gst/gsttypefindfactory.c
@@ -61,7 +61,6 @@
* GList *walk, *type_list;
* MyTypeFind find = {data, size, 0, NULL};
* GstTypeFind gst_find = {my_peek, my_suggest, &find, };
- *
* walk = type_list = gst_type_find_factory_get_list ();
* while (walk) {
* GstTypeFindFactory *factory = GST_TYPE_FIND_FACTORY (walk->data);
diff --git a/libs/gst/check/gstcheck.c b/libs/gst/check/gstcheck.c
index f1c05a0570..54093bf21d 100644
--- a/libs/gst/check/gstcheck.c
+++ b/libs/gst/check/gstcheck.c
@@ -168,7 +168,8 @@ gst_check_setup_src_pad (GstElement * element,
fail_if (sinkpad == NULL, "Could not get sink pad from %s",
GST_ELEMENT_NAME (element));
ASSERT_OBJECT_REFCOUNT (sinkpad, "sinkpad", 2);
- fail_unless (gst_pad_set_caps (srcpad, caps));
+ if (caps)
+ fail_unless (gst_pad_set_caps (srcpad, caps));
fail_unless (gst_pad_link (srcpad, sinkpad) == GST_PAD_LINK_OK,
"Could not link source and %s sink pads", GST_ELEMENT_NAME (element));
gst_object_unref (sinkpad); /* because we got it higher up */
@@ -218,7 +219,8 @@ gst_check_setup_sink_pad (GstElement * element, GstStaticPadTemplate * template,
srcpad = gst_element_get_pad (element, "src");
fail_if (srcpad == NULL, "Could not get source pad from %s",
GST_ELEMENT_NAME (element));
- fail_unless (gst_pad_set_caps (sinkpad, caps));
+ if (caps)
+ fail_unless (gst_pad_set_caps (sinkpad, caps));
gst_pad_set_chain_function (sinkpad, gst_check_chain_func);
fail_unless (gst_pad_link (srcpad, sinkpad) == GST_PAD_LINK_OK,