From: Yu Watanabe Date: Mon, 22 Feb 2021 14:11:28 +0000 (+0900) Subject: backlight: same_device() may return negative errno X-Git-Tag: v248-rc1~15^2~2 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=ba6c9b79945109ec14f17b48e9b1931c037ebc90;p=thirdparty%2Fsystemd.git backlight: same_device() may return negative errno --- diff --git a/src/backlight/backlight.c b/src/backlight/backlight.c index f9e4f83ab96..2e2938674d7 100644 --- a/src/backlight/backlight.c +++ b/src/backlight/backlight.c @@ -200,7 +200,7 @@ static int validate_device(sd_device *device) { if (find_pci_or_platform_parent(other, &other_parent) < 0) continue; - if (same_device(parent, other_parent)) { + if (same_device(parent, other_parent) > 0) { const char *device_sysname = NULL, *other_sysname = NULL; /* Both have the same PCI parent, that means we are out. */