From: Thomas Hindoe Paaboel Andersen Date: Sun, 27 Dec 2015 22:57:58 +0000 (+0100) Subject: resolve-host: add error checking X-Git-Tag: v231~826^2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=f770083430d03d7fe8b5771b6ef269802735e914;p=platform%2Fupstream%2Fsystemd.git resolve-host: add error checking --- diff --git a/src/resolve-host/resolve-host.c b/src/resolve-host/resolve-host.c index 67c93c2..fa0dffc 100644 --- a/src/resolve-host/resolve-host.c +++ b/src/resolve-host/resolve-host.c @@ -690,6 +690,8 @@ static int show_statistics(sd_bus *bus) { &error, &reply, "(ttt)"); + if (r < 0) + return log_error_errno(r, "Failed to get cache statistics: %s", bus_error_message(&error, r)); r = sd_bus_message_read(reply, "(ttt)", &cache_size, @@ -718,6 +720,8 @@ static int show_statistics(sd_bus *bus) { &error, &reply, "(tttt)"); + if (r < 0) + return log_error_errno(r, "Failed to get DNSSEC statistics: %s", bus_error_message(&error, r)); r = sd_bus_message_read(reply, "(tttt)", &n_dnssec_secure,