]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
systemctl: format IPIngressBytes= or friends nicely
authorYu Watanabe <watanabe.yu+github@gmail.com>
Sat, 2 Mar 2019 16:35:18 +0000 (01:35 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Mon, 4 Mar 2019 14:45:07 +0000 (23:45 +0900)
src/shared/bus-util.c

index 90cddd7e04d8e5e2fff61d74256b0f19aeb34308..1911dd0ce642f875db511e9b5c56da66752d1942 100644 (file)
@@ -800,6 +800,8 @@ static int bus_print_property(const char *name, const char *expected_value, sd_b
                          (startswith(name, "DefaultLimit") && u == (uint64_t) -1))
 
                         bus_print_property_value(name, expected_value, value, "infinity");
+                else if (STR_IN_SET(name, "IPIngressBytes", "IPIngressPackets", "IPEgressBytes", "IPEgressPackets") && u == (uint64_t) -1)
+                        bus_print_property_value(name, expected_value, value, "[no data]");
                 else
                         bus_print_property_valuef(name, expected_value, value, "%"PRIu64, u);