1
1
mirror of https://github.com/systemd/systemd-stable.git synced 2024-10-27 18:55:09 +03:00

homectl: add missing log messages when json_variant_format() fails

This commit is contained in:
Lennart Poettering 2020-04-15 19:31:33 +02:00
parent c63ec11bf5
commit 7b8d55b72c

View File

@ -1423,7 +1423,7 @@ static int create_home(int argc, char *argv[], void *userdata) {
r = json_variant_format(hr->json, 0, &formatted); r = json_variant_format(hr->json, 0, &formatted);
if (r < 0) if (r < 0)
return r; return log_error_errno(r, "Failed to format user record: %m");
r = bus_message_new_method_call(bus, &m, bus_home_mgr, "CreateHome"); r = bus_message_new_method_call(bus, &m, bus_home_mgr, "CreateHome");
if (r < 0) if (r < 0)
@ -1631,7 +1631,7 @@ static int update_home(int argc, char *argv[], void *userdata) {
r = json_variant_format(hr->json, 0, &formatted); r = json_variant_format(hr->json, 0, &formatted);
if (r < 0) if (r < 0)
return r; return log_error_errno(r, "Failed to format user record: %m");
(void) sd_bus_message_sensitive(m); (void) sd_bus_message_sensitive(m);