From: Yu Watanabe Date: Sat, 26 Apr 2025 00:29:40 +0000 (+0900) Subject: core/device: fix meaningless assertion X-Git-Tag: v258-rc1~734^2~2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d6891af577db16dedb7a67aea5f310054c6ef852;p=thirdparty%2Fsystemd.git core/device: fix meaningless assertion Closes CID#1609498. --- diff --git a/src/core/device.c b/src/core/device.c index 08235caa42c..ea06f0ccb49 100644 --- a/src/core/device.c +++ b/src/core/device.c @@ -364,7 +364,7 @@ static const struct { static int device_found_to_string_many(DeviceFound flags, char **ret) { _cleanup_free_ char *s = NULL; - assert(flags >= 0); + assert((flags & ~_DEVICE_FOUND_MASK) == 0); assert(ret); FOREACH_ELEMENT(i, device_found_map) {