summaryrefslogtreecommitdiff
path: root/src/core/scope.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2016-12-11 20:38:15 +0100
committerGitHub <noreply@github.com>2016-12-11 20:38:15 +0100
commit15ffcc3456e054c0f9fd293afe449fed292b5d38 (patch)
tree896604e75290681f4361f2d67a880f80d2a7de9c /src/core/scope.c
parent4682047cf23f3471894d83d847cdac6b3bec92e1 (diff)
parent9e35b3de429890ed836271dc0ccbd821ab0c204a (diff)
Merge pull request #4859 from keszybz/networkd
Networkd man page update and fixes for the fallout
Diffstat (limited to 'src/core/scope.c')
-rw-r--r--src/core/scope.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/core/scope.c b/src/core/scope.c
index d6e1f8e392..9540fb67d9 100644
--- a/src/core/scope.c
+++ b/src/core/scope.c
@@ -273,7 +273,9 @@ static void scope_enter_signal(Scope *s, ScopeState state, ScopeResult f) {
if (state == SCOPE_STOP_SIGTERM)
skip_signal = bus_scope_send_request_stop(s) > 0;
- if (!skip_signal) {
+ if (skip_signal)
+ r = 1; /* wait */
+ else {
r = unit_kill_context(
UNIT(s),
&s->kill_context,
@@ -283,8 +285,7 @@ static void scope_enter_signal(Scope *s, ScopeState state, ScopeResult f) {
-1, -1, false);
if (r < 0)
goto fail;
- } else
- r = 1;
+ }
if (r > 0) {
r = scope_arm_timer(s, usec_add(now(CLOCK_MONOTONIC), s->timeout_stop_usec));