chiark / gitweb /
core: failed scope units may not be restarted
authorLennart Poettering <lennart@poettering.net>
Wed, 11 Sep 2013 17:26:47 +0000 (19:26 +0200)
committerLennart Poettering <lennart@poettering.net>
Wed, 11 Sep 2013 17:28:28 +0000 (19:28 +0200)
We don't allow reusing of scopes.

TODO
src/core/scope.c

diff --git a/TODO b/TODO
index 5fd9a59a7d0fd343b4984cca03cb58ac1abc61c7..519657fa8118a229c2a201f63104ae4b4ab5b84b 100644 (file)
--- a/TODO
+++ b/TODO
@@ -58,6 +58,8 @@ CGroup Rework Completion:
 
 Features:
 
 
 Features:
 
+* ensure scope units may be started only a single time
+
 * document that in instead of FsckPassNo= people should just add a manual dep to systemd-fsck@.service to their mount units.
 
 * better error message if you run systemctl without systemd running
 * document that in instead of FsckPassNo= people should just add a manual dep to systemd-fsck@.service to their mount units.
 
 * better error message if you run systemctl without systemd running
index 20a969d913d30c605a61304ef3654ea4dffed9de..b94f3ff7ba2758c50d3946b9bd3c634bc39186ea 100644 (file)
@@ -239,6 +239,9 @@ static int scope_start(Unit *u) {
 
         assert(s);
 
 
         assert(s);
 
+        if (s->state == SCOPE_FAILED)
+                return -EPERM;
+
         if (s->state == SCOPE_STOP_SIGTERM ||
             s->state == SCOPE_STOP_SIGKILL)
                 return -EAGAIN;
         if (s->state == SCOPE_STOP_SIGTERM ||
             s->state == SCOPE_STOP_SIGKILL)
                 return -EAGAIN;