From: Michal Privoznik Date: Mon, 1 Oct 2012 12:22:42 +0000 (+0200) Subject: lxc: Correctly report active cgroups X-Git-Tag: v1.0.0-rc1~183 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0dddd680c267eecfb0eeaa7b3a52f563089c6301;p=thirdparty%2Flibvirt.git lxc: Correctly report active cgroups There was an inverted return value in lxcCgroupControllerActive(). The function assumes cgroups are active and do couple of checks to prove that. If any of them fails, false is returned. Therefore, at the end, after all checks are done we must return true, not false. --- diff --git a/src/lxc/lxc_driver.c b/src/lxc/lxc_driver.c index ae5163e495..87305dbfc5 100644 --- a/src/lxc/lxc_driver.c +++ b/src/lxc/lxc_driver.c @@ -1645,7 +1645,7 @@ static bool lxcCgroupControllerActive(virLXCDriverPtr driver, if (driver->cgroupControllers & (1 << controller)) return true; #endif - return false; + return true; }