From: Tejun Heo Date: Mon, 23 May 2016 20:48:46 +0000 (-0400) Subject: core: fix the reversed sanity check when setting StartupBlockIOWeight over dbus X-Git-Tag: v231~251^2~1 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=6fb09269769634df1096663ce90fac47585eb63a;p=thirdparty%2Fsystemd.git core: fix the reversed sanity check when setting StartupBlockIOWeight over dbus bus_cgroup_set_property() was rejecting if the input value was in range. Reverse it. --- diff --git a/src/core/dbus-cgroup.c b/src/core/dbus-cgroup.c index eef1c47c14d..76f07c550d3 100644 --- a/src/core/dbus-cgroup.c +++ b/src/core/dbus-cgroup.c @@ -623,7 +623,7 @@ int bus_cgroup_set_property( if (r < 0) return r; - if (CGROUP_BLKIO_WEIGHT_IS_OK(weight)) + if (!CGROUP_BLKIO_WEIGHT_IS_OK(weight)) return sd_bus_error_set_errnof(error, EINVAL, "StartupBlockIOWeight value out of range"); if (mode != UNIT_CHECK) {