diff options
author | fangxiuning <fangxiuning123@126.com> | 2020-07-11 12:13:01 +0200 |
---|---|---|
committer | Yu Watanabe <watanabe.yu+github@gmail.com> | 2020-07-11 23:33:48 +0200 |
commit | d67b1d18fcda2c8c5aacfc50f9591c8dc7a4a8a1 (patch) | |
tree | 1de2ce9110b24bf9e8bc278ff77d75cca7aa1c62 | |
parent | Merge pull request #16424 from keszybz/cap-bpf-compat (diff) | |
download | systemd-d67b1d18fcda2c8c5aacfc50f9591c8dc7a4a8a1.tar.xz systemd-d67b1d18fcda2c8c5aacfc50f9591c8dc7a4a8a1.zip |
bus: use bus_log_parse_error to print message
-rw-r--r-- | src/busctl/busctl.c | 2 | ||||
-rw-r--r-- | src/network/networkd-manager.c | 2 | ||||
-rw-r--r-- | src/resolve/resolved-bus.c | 2 | ||||
-rw-r--r-- | src/timedate/timedatectl.c | 2 |
4 files changed, 4 insertions, 4 deletions
diff --git a/src/busctl/busctl.c b/src/busctl/busctl.c index 56fb8d9367..ccb22d5f8b 100644 --- a/src/busctl/busctl.c +++ b/src/busctl/busctl.c @@ -1322,7 +1322,7 @@ static int monitor(int argc, char **argv, int (*dump)(sd_bus_message *m, FILE *f r = sd_bus_message_read(m, "s", &name); if (r < 0) - return log_error_errno(r, "Failed to read lost name: %m"); + return bus_log_parse_error(r); if (streq(name, unique_name)) is_monitor = true; diff --git a/src/network/networkd-manager.c b/src/network/networkd-manager.c index 63e2f61d29..8c51cc12b2 100644 --- a/src/network/networkd-manager.c +++ b/src/network/networkd-manager.c @@ -104,7 +104,7 @@ static int match_prepare_for_sleep(sd_bus_message *message, void *userdata, sd_b r = sd_bus_message_read(message, "b", &b); if (r < 0) { - log_debug_errno(r, "Failed to parse PrepareForSleep signal: %m"); + bus_log_parse_error(r); return 0; } diff --git a/src/resolve/resolved-bus.c b/src/resolve/resolved-bus.c index 2ecfcf498b..45687c8fca 100644 --- a/src/resolve/resolved-bus.c +++ b/src/resolve/resolved-bus.c @@ -1987,7 +1987,7 @@ static int match_prepare_for_sleep(sd_bus_message *message, void *userdata, sd_b r = sd_bus_message_read(message, "b", &b); if (r < 0) { - log_debug_errno(r, "Failed to parse PrepareForSleep signal: %m"); + bus_log_parse_error(r); return 0; } diff --git a/src/timedate/timedatectl.c b/src/timedate/timedatectl.c index eaac3b3e35..49d68d2533 100644 --- a/src/timedate/timedatectl.c +++ b/src/timedate/timedatectl.c @@ -664,7 +664,7 @@ static int on_properties_changed(sd_bus_message *m, void *userdata, sd_bus_error r = sd_bus_message_read(m, "s", &name); if (r < 0) - return log_error_errno(r, "Failed to read interface name: %m"); + return bus_log_parse_error(r); if (!streq_ptr(name, "org.freedesktop.timesync1.Manager")) return 0; |