From a6f60fcf2e7642747b53adc47f0cd453392c408c Mon Sep 17 00:00:00 2001 From: Stefan Sauer Date: Fri, 25 Oct 2013 21:29:01 +0200 Subject: [PATCH] registry: small cleanups and use object log variants more --- gst/gstregistrychunks.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/gst/gstregistrychunks.c b/gst/gstregistrychunks.c index 60ed42e227..0ee7a0506c 100644 --- a/gst/gstregistrychunks.c +++ b/gst/gstregistrychunks.c @@ -227,7 +227,7 @@ G_STMT_START { \ static gboolean gst_registry_chunks_save_feature (GList ** list, GstPluginFeature * feature) { - const gchar *type_name = g_type_name (G_OBJECT_TYPE (feature)); + const gchar *type_name = G_OBJECT_TYPE_NAME (feature); GstRegistryChunkPluginFeature *pf = NULL; GstRegistryChunk *chk = NULL; GList *walk; @@ -256,8 +256,8 @@ gst_registry_chunks_save_feature (GList ** list, GstPluginFeature * feature) walk = g_list_next (walk), ef->ninterfaces++) { gst_registry_chunks_save_const_string (list, (gchar *) walk->data); } - GST_DEBUG ("Feature %s: saved %d interfaces %d pad templates", - GST_OBJECT_NAME (feature), ef->ninterfaces, ef->npadtemplates); + GST_DEBUG_OBJECT (feature, "saved %d interfaces %d pad templates", + ef->ninterfaces, ef->npadtemplates); /* save uritypes */ if (GST_URI_TYPE_IS_VALID (factory->uri_type)) { @@ -276,7 +276,7 @@ gst_registry_chunks_save_feature (GList ** list, GstPluginFeature * feature) ef->nuriprotocols++; } *list = g_list_prepend (*list, subchk); - GST_DEBUG ("Saved %d UriTypes", ef->nuriprotocols); + GST_DEBUG_OBJECT (feature, "Saved %d UriTypes", ef->nuriprotocols); } else { g_warning ("GStreamer feature '%s' is URI handler but does not provide" " any protocols it can handle", GST_OBJECT_NAME (feature)); @@ -289,7 +289,7 @@ gst_registry_chunks_save_feature (GList ** list, GstPluginFeature * feature) GstStaticPadTemplate *template = walk->data; if (!gst_registry_chunks_save_pad_template (list, template)) { - GST_ERROR ("Can't fill pad template, aborting."); + GST_ERROR_OBJECT (feature, "Can't fill pad template, aborting."); goto fail; } } @@ -318,6 +318,7 @@ gst_registry_chunks_save_feature (GList ** list, GstPluginFeature * feature) factory->extensions[tff->nextensions++]); } } + GST_DEBUG_OBJECT (feature, "saved %d extensions", tff->nextensions); /* save caps */ if (factory->caps) { GstCaps *fcaps = gst_caps_ref (factory->caps); @@ -332,7 +333,7 @@ gst_registry_chunks_save_feature (GList ** list, GstPluginFeature * feature) gst_registry_chunks_save_const_string (list, ""); } } else { - GST_WARNING ("unhandled feature type '%s'", type_name); + GST_WARNING_OBJECT (feature, "unhandled feature type '%s'", type_name); } if (pf) {