diff options
author | INSUN PYO <insun.pyo@samsung.com> | 2018-11-13 13:44:20 +0900 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2018-11-13 10:39:35 +0100 |
commit | 8724defeae4c6da9e5816e88dec4138c5f909932 (patch) | |
tree | 439d8f749074754c9d952d2903f3d5ef6cc4c007 | |
parent | 53a3e8fc7a2db3654380f2c32fe16653227fcf0f (diff) | |
download | systemd-8724defeae4c6da9e5816e88dec4138c5f909932.tar.gz |
core: use local variable m instead of u->manager
-rw-r--r-- | src/core/unit.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/src/core/unit.c b/src/core/unit.c index 58e67c1b8c..955fa40c50 100644 --- a/src/core/unit.c +++ b/src/core/unit.c @@ -2371,7 +2371,7 @@ void unit_notify(Unit *u, UnitActiveState os, UnitActiveState ns, UnitNotifyFlag } /* Keep track of failed units */ - (void) manager_update_failed_units(u->manager, u, ns == UNIT_FAILED); + (void) manager_update_failed_units(m, u, ns == UNIT_FAILED); /* Make sure the cgroup and state files are always removed when we become inactive */ if (UNIT_IS_INACTIVE_OR_FAILED(ns)) { @@ -2516,7 +2516,7 @@ void unit_notify(Unit *u, UnitActiveState os, UnitActiveState ns, UnitNotifyFlag unit_trigger_notify(u); - if (!MANAGER_IS_RELOADING(u->manager)) { + if (!MANAGER_IS_RELOADING(m)) { /* Maybe we finished startup and are now ready for being stopped because unneeded? */ unit_submit_to_stop_when_unneeded_queue(u); @@ -2527,12 +2527,10 @@ void unit_notify(Unit *u, UnitActiveState os, UnitActiveState ns, UnitNotifyFlag if (os != UNIT_FAILED && ns == UNIT_FAILED) { reason = strjoina("unit ", u->id, " failed"); - (void) emergency_action(u->manager, u->failure_action, 0, - u->reboot_arg, reason); + (void) emergency_action(m, u->failure_action, 0, u->reboot_arg, reason); } else if (!UNIT_IS_INACTIVE_OR_FAILED(os) && ns == UNIT_INACTIVE) { reason = strjoina("unit ", u->id, " succeeded"); - (void) emergency_action(u->manager, u->success_action, 0, - u->reboot_arg, reason); + (void) emergency_action(m, u->success_action, 0, u->reboot_arg, reason); } } |