1
0
mirror of https://github.com/systemd/systemd.git synced 2024-10-31 16:21:26 +03:00

manager: remove unnecessary conditional

This commit is contained in:
Zbigniew Jędrzejewski-Szmek 2021-01-30 17:27:45 +01:00
parent 9466ec13a5
commit ef3fc326b9

View File

@ -1188,18 +1188,15 @@ static void unit_gc_sweep(Unit *u, unsigned gc_marker) {
is_bad = false;
}
if (u->refs_by_target) {
const UnitRef *ref;
const UnitRef *ref;
LIST_FOREACH(refs_by_target, ref, u->refs_by_target) {
unit_gc_sweep(ref->source, gc_marker);
LIST_FOREACH(refs_by_target, ref, u->refs_by_target) {
unit_gc_sweep(ref->source, gc_marker);
if (ref->source->gc_marker == gc_marker + GC_OFFSET_GOOD)
goto good;
if (ref->source->gc_marker == gc_marker + GC_OFFSET_GOOD)
goto good;
if (ref->source->gc_marker != gc_marker + GC_OFFSET_BAD)
is_bad = false;
}
if (ref->source->gc_marker != gc_marker + GC_OFFSET_BAD)
is_bad = false;
}
if (is_bad)