systemctl: make sure daemon-reload returns success

Also change sd_bus_message_exit_container to return -ENOENT
when not in a container, to make it easier to distinguish different
errors.
This commit is contained in:
Zbigniew Jędrzejewski-Szmek
2013-11-09 19:41:00 -05:00
parent 7c99d940c1
commit 0a9776c230
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -3018,7 +3018,7 @@ _public_ int sd_bus_message_exit_container(sd_bus_message *m) {
assert_return(m, -EINVAL);
assert_return(m->sealed, -EPERM);
assert_return(m->n_containers > 0, -EINVAL);
assert_return(m->n_containers > 0, -ENOENT);
c = message_get_container(m);
if (c->enclosing == SD_BUS_TYPE_ARRAY) {
+1 -1
View File
@@ -3762,7 +3762,7 @@ static int daemon_reload(sd_bus *bus, char **args) {
else if (r < 0)
log_error("Failed to execute operation: %s", bus_error_message(&error, r));
return r;
return r < 0 ? r : 0;
}
static int reset_failed(sd_bus *bus, char **args) {