chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
488ad3b
)
systemctl: skip native unit file handling if sysv file handling already handled every...
author
Lennart Poettering
<lennart@poettering.net>
Mon, 20 Jan 2014 12:43:20 +0000
(13:43 +0100)
committer
Lennart Poettering
<lennart@poettering.net>
Mon, 20 Jan 2014 12:43:57 +0000
(13:43 +0100)
Issue pointed out by Colin Guthrie.
src/systemctl/systemctl.c
patch
|
blob
|
history
diff --git
a/src/systemctl/systemctl.c
b/src/systemctl/systemctl.c
index b9d9b3aa961e8ace832a607d5a842a655f0c6aac..d850b8bdf204f736efeafcd41505fd3537762f25 100644
(file)
--- a/
src/systemctl/systemctl.c
+++ b/
src/systemctl/systemctl.c
@@
-4740,6
+4740,11
@@
static int enable_unit(sd_bus *bus, char **args) {
if (r < 0)
return r;
if (r < 0)
return r;
+ /* If the operation was fully executed by the SysV compat,
+ * let's finish early */
+ if (strv_isempty(names))
+ return 0;
+
if (!bus || avoid_bus()) {
if (streq(verb, "enable")) {
r = unit_file_enable(arg_scope, arg_runtime, arg_root, names, arg_force, &changes, &n_changes);
if (!bus || avoid_bus()) {
if (streq(verb, "enable")) {
r = unit_file_enable(arg_scope, arg_runtime, arg_root, names, arg_force, &changes, &n_changes);