From: Mike Yuan Date: Wed, 31 Jul 2024 17:53:53 +0000 (+0200) Subject: core/cgroup: use UNIT_IS_INACTIVE_OR_FAILED where appropriate X-Git-Tag: v257-rc1~785^2~1 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=067c91fcb8991e83dffcf922f7f4faddf2cc49b1;p=thirdparty%2Fsystemd.git core/cgroup: use UNIT_IS_INACTIVE_OR_FAILED where appropriate --- diff --git a/src/core/cgroup.c b/src/core/cgroup.c index 50dd3dd45d9..3f96f64dad2 100644 --- a/src/core/cgroup.c +++ b/src/core/cgroup.c @@ -3788,7 +3788,7 @@ static int on_cgroup_empty_event(sd_event_source *s, void *userdata) { unit_add_to_gc_queue(u); - if (IN_SET(unit_active_state(u), UNIT_INACTIVE, UNIT_FAILED)) + if (UNIT_IS_INACTIVE_OR_FAILED(unit_active_state(u))) unit_prune_cgroup(u); else if (UNIT_VTABLE(u)->notify_cgroup_empty) UNIT_VTABLE(u)->notify_cgroup_empty(u);