From a14bc47072eb9ed796c2ba2400a73c9c57e2f534 Mon Sep 17 00:00:00 2001 From: Christian Pointner Date: Thu, 2 Oct 2014 03:40:18 +0200 Subject: added some names for bins --- src/utils.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src/utils.c') diff --git a/src/utils.c b/src/utils.c index b1bcee3..abeb595 100644 --- a/src/utils.c +++ b/src/utils.c @@ -51,19 +51,20 @@ gint cmp_udp_client(gconstpointer A, gconstpointer B) return strncmp(a->host_.addr_, b->host_.addr_, sizeof(a->host_.addr_)); } -GstElement* sydra_create_bin_from_desc(const char* type, const char* desc, gboolean ghost_unlinked_pads) +GstElement* sydra_create_bin_from_desc(const char* name, const char* desc, gboolean ghost_unlinked_pads) { GError *error = NULL; GstElement *bin = gst_parse_bin_from_description(desc, ghost_unlinked_pads, &error); if(!bin) { - log_printf(ERROR, "Bin description for %s parser error: %s", type, error ? error->message : "unknown"); + log_printf(ERROR, "Bin description for %s parser error: %s", name, error ? error->message : "unknown"); g_error_free(error); return NULL; } if(error) { - log_printf(WARNING, "Bin description for %s parser warning: %s", type, error ? error->message : "unknown"); + log_printf(WARNING, "Bin description for %s parser warning: %s", name, error ? error->message : "unknown"); g_error_free(error); } + gst_element_set_name(bin, name); return bin; } -- cgit v1.2.3