From: Rafał Miłecki Date: Wed, 15 Feb 2017 10:29:00 +0000 (+0100) Subject: Fix error messages when sending packet fails X-Git-Url: http://git.openwrt.org/?p=project%2Fmdnsd.git;a=commitdiff_plain;h=61f6854cea03e9e170720134713a7c18165ac6df Fix error messages when sending packet fails Use perror in both cases, fix copy & paste mistake, don't use extra ":". Signed-off-by: Rafał Miłecki --- diff --git a/dns.c b/dns.c index cf9e29b..7c49236 100644 --- a/dns.c +++ b/dns.c @@ -99,7 +99,7 @@ dns_send_question(struct interface *iface, const char *question, int type, int m DBG(1, "Q <- %s %s\n", dns_type_string(type), question); if (interface_send_packet(iface, NULL, iov, ARRAY_SIZE(iov)) < 0) - perror("failed to send question :"); + perror("failed to send question"); } @@ -178,7 +178,7 @@ dns_send_answer(struct interface *iface, struct sockaddr *to, const char *answer } if (interface_send_packet(iface, to, iov, n_iov) < 0) - fprintf(stderr, "failed to send question\n"); + perror("failed to send answer"); } void