mirror of
https://github.com/systemd/systemd.git
synced 2024-12-28 19:43:30 +08:00
unit: don't retroactively start units if we failed to shutdown a unit
This commit is contained in:
parent
53c6a358a8
commit
5ed9f5d65e
@ -1084,7 +1084,7 @@ void unit_notify(Unit *u, UnitActiveState os, UnitActiveState ns) {
|
||||
* something is already activated. */
|
||||
|
||||
if (unexpected && u->meta.manager->n_deserializing <= 0) {
|
||||
if (UNIT_IS_INACTIVE_OR_DEACTIVATING(os) && UNIT_IS_ACTIVE_OR_ACTIVATING(ns))
|
||||
if (UNIT_IS_INACTIVE_OR_FAILED(os) && UNIT_IS_ACTIVE_OR_ACTIVATING(ns))
|
||||
retroactively_start_dependencies(u);
|
||||
else if (UNIT_IS_ACTIVE_OR_ACTIVATING(os) && UNIT_IS_INACTIVE_OR_DEACTIVATING(ns))
|
||||
retroactively_stop_dependencies(u);
|
||||
|
Loading…
Reference in New Issue
Block a user