diff options
author | Lennart Poettering <lennart@poettering.net> | 2014-12-29 20:00:01 +0100 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2014-12-29 20:13:58 +0100 |
commit | c00a4c8f55e51be98274e86beba14117e25dab9c (patch) | |
tree | 71730d8327d73dae42421127bfc5fd251aacaa6c /src/machine/machine.c | |
parent | e5f5b5b9c92d59ef3cb5169982cb6f436c9206fa (diff) |
Revert "machined: don't force terminate registered machines"
This reverts commit 206e7a5f7b55ac61188efd895e65ab26e478cbb2.
We actually want to allow shutting down containers that use
RegisterMachine() rather than CreateMachine() to register their own
unit. It should be safe to do so, since the primary usecase for
RegisterMachine() are container managers that run only a single
container within their own unit, such as systemd-nspawn.
Diffstat (limited to 'src/machine/machine.c')
-rw-r--r-- | src/machine/machine.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/src/machine/machine.c b/src/machine/machine.c index 8dec716d71..b283118796 100644 --- a/src/machine/machine.c +++ b/src/machine/machine.c @@ -406,12 +406,10 @@ static int machine_stop_scope(Machine *m) { if (!m->unit) return 0; - if (!m->registered) { - r = manager_stop_unit(m->manager, m->unit, &error, &job); - if (r < 0) { - log_error("Failed to stop machine scope: %s", bus_error_message(&error, r)); - return r; - } + r = manager_stop_unit(m->manager, m->unit, &error, &job); + if (r < 0) { + log_error("Failed to stop machine scope: %s", bus_error_message(&error, r)); + return r; } free(m->scope_job); |