X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=blobdiff_plain;f=src%2Fsystemctl.c;h=99ada38309b7e3ab02a94f99b52e270cc79b7ae4;hb=ec195f55fb279b0eb6a38bc8ea15ff1afbdcae80;hp=d1d73bfa01397d5af617dbd69d6cd39454db13f3;hpb=54e4fdef80693f7fd7893bd048bb4d9a258b03a6;p=elogind.git diff --git a/src/systemctl.c b/src/systemctl.c index d1d73bfa0..99ada3830 100644 --- a/src/systemctl.c +++ b/src/systemctl.c @@ -3323,6 +3323,13 @@ static int daemon_reload(DBusConnection *bus, char **args, unsigned n) { goto finish; } + if (streq(method, "Reexecute") && dbus_error_has_name(&error, DBUS_ERROR_NO_REPLY)) { + /* On reexecution, we expect a disconnect, not + * a reply */ + r = 0; + goto finish; + } + log_error("Failed to issue method call: %s", bus_error_message(&error)); r = -EIO; goto finish; @@ -4157,8 +4164,7 @@ static int install_info_apply(const char *verb, LookupPaths *paths, InstallInfo if (streq(verb, "is-enabled") && strv_isempty(i->aliases) && strv_isempty(i->wanted_by) && - (path_startswith(filename, "/lib") || - path_startswith(filename, "/usr"))) + !path_startswith(filename, "/etc")) return 1; i->path = filename;