chiark / gitweb /
resolved: silence warnings
authorThomas Hindoe Paaboel Andersen <phomes@gmail.com>
Thu, 17 Jul 2014 19:12:39 +0000 (21:12 +0200)
committerThomas Hindoe Paaboel Andersen <phomes@gmail.com>
Thu, 17 Jul 2014 19:12:39 +0000 (21:12 +0200)
No need to write to r here since it will be overwritten as the first
step in parse_fail.

src/resolve/resolved-bus.c

index c5e298d..f486fcd 100644 (file)
@@ -145,10 +145,8 @@ static void bus_method_resolve_hostname_complete(DnsQuery *q) {
         }
 
         n = dns_query_get_rrs(q, &rrs);
-        if (n < 0) {
-                r = n;
+        if (n < 0)
                 goto parse_fail;
-        }
 
         r = sd_bus_message_new_method_return(q->request, &reply);
         if (r < 0)
@@ -337,10 +335,8 @@ static void bus_method_resolve_address_complete(DnsQuery *q) {
         }
 
         n = dns_query_get_rrs(q, &rrs);
-        if (n < 0) {
-                r = n;
+        if (n < 0)
                 goto parse_fail;
-        }
 
         r = sd_bus_message_new_method_return(q->request, &reply);
         if (r < 0)