From: David Goulet Date: Wed, 25 Jul 2012 14:18:41 +0000 (-0400) Subject: Fix: some error in uri.c were still using printf() X-Git-Tag: v2.1.0-rc1~52 X-Git-Url: https://git.lttng.org/?p=lttng-tools.git;a=commitdiff_plain;h=b3e122872d4f6464ebcbc341b4fa4108c8a9d4a5 Fix: some error in uri.c were still using printf() Signed-off-by: David Goulet --- diff --git a/src/common/uri.c b/src/common/uri.c index f97b0bba8..6ca46474f 100644 --- a/src/common/uri.c +++ b/src/common/uri.c @@ -91,7 +91,7 @@ static int set_ip_address(const char *addr, int af, char *dst, size_t size) record = gethostbyname2(addr, af); if (record == NULL) { /* At this point, the IP or the hostname is bad */ - printf("bad hostname\n"); + ERR("URI parse bad hostname %s for af %d", addr, af); goto error; } @@ -175,7 +175,7 @@ ssize_t uri_parse(const char *str_uri, struct lttng_uri **uris) ret = sscanf(str_uri, "%5[^:]://", net); if (ret < 1) { - printf("bad protocol\n"); + ERR("URI parse bad protocol %s", str_uri); goto error; } @@ -183,7 +183,7 @@ ssize_t uri_parse(const char *str_uri, struct lttng_uri **uris) proto = validate_protocol(net); if (proto == NULL) { - printf("no protocol\n"); + ERR("URI parse unknown protocol %s", net); ret = -1; goto error; }