[systemd-commits] TODO src/core

Lennart Poettering lennart at kemper.freedesktop.org
Wed Sep 11 10:28:36 PDT 2013


 TODO             |    2 ++
 src/core/scope.c |    3 +++
 2 files changed, 5 insertions(+)

New commits:
commit 7b617155b50fdaad5d06359eb03e98f0c7b3087b
Author: Lennart Poettering <lennart at poettering.net>
Date:   Wed Sep 11 19:26:47 2013 +0200

    core: failed scope units may not be restarted
    
    We don't allow reusing of scopes.

diff --git a/TODO b/TODO
index 5fd9a59..519657f 100644
--- a/TODO
+++ b/TODO
@@ -58,6 +58,8 @@ CGroup Rework Completion:
 
 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 at .service to their mount units.
 
 * better error message if you run systemctl without systemd running
diff --git a/src/core/scope.c b/src/core/scope.c
index 20a969d..b94f3ff 100644
--- a/src/core/scope.c
+++ b/src/core/scope.c
@@ -239,6 +239,9 @@ static int scope_start(Unit *u) {
 
         assert(s);
 
+        if (s->state == SCOPE_FAILED)
+                return -EPERM;
+
         if (s->state == SCOPE_STOP_SIGTERM ||
             s->state == SCOPE_STOP_SIGKILL)
                 return -EAGAIN;



More information about the systemd-commits mailing list