core/unit: unit_is_filtered() -> unit_passes_filter() and invert logic

Follow-up for 6d2984d21b

The current semantics of "filtered" in unit_is_filtered()
are actually the contrary of ListUnitsFiltered(). Let's
make things consistent, i.e. return true when the unit
shall be included.
This commit is contained in:
Mike Yuan
2024-08-17 20:09:51 +02:00
parent 6c8ade3066
commit 6e0f959360
4 changed files with 6 additions and 7 deletions
-1
View File
@@ -235,7 +235,6 @@ bool strv_fnmatch_full(char* const* patterns, const char *s, int flags, size_t *
static inline bool strv_fnmatch(char* const* patterns, const char *s) {
return strv_fnmatch_full(patterns, s, 0, NULL);
}
static inline bool strv_fnmatch_or_empty(char* const* patterns, const char *s, int flags) {
assert(s);
return strv_isempty(patterns) ||