From be982f880df6388bd00386b2cae8c318f902f1b2 Mon Sep 17 00:00:00 2001 From: Christian Pointner Date: Wed, 24 Sep 2014 23:34:21 +0200 Subject: moved pipeline creation subs to own file --- src/utils.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'src/utils.c') diff --git a/src/utils.c b/src/utils.c index e9466fa..1180b0a 100644 --- a/src/utils.c +++ b/src/utils.c @@ -36,8 +36,21 @@ #include "datatypes.h" #include "utils.h" #include "log.h" + +#include + #include +gint cmp_addr_port(gconstpointer A, gconstpointer B) +{ + const struct addr_port *a = (const struct addr_port *)A; + const struct addr_port *b = (const struct addr_port *)B; + + if(a->type_ != b->type_ || a->port_ != b->port_) + return -1; + return strncmp(a->addr_, b->addr_, sizeof(a->addr_)); +} + GstElement* sydra_create_bin_from_desc(const char* type, const char* desc) { GError *error = NULL; -- cgit v1.2.3