]> git.ipfire.org Git - thirdparty/lxc.git/commitdiff
Update file capa detection for kernels >=2.6.37
authorJan Niehusmann <jan@gondor.com>
Sat, 26 Feb 2011 09:18:19 +0000 (10:18 +0100)
committerDaniel Lezcano <dlezcano@fr.ibm.com>
Sat, 26 Feb 2011 09:18:19 +0000 (10:18 +0100)
The comment containing the version number at the beginning of the kernel
config file changed its format with 2.6.37. This trivial patch makes the
grep less specific, so it triggers for both formats.

Signed-off-by: Daniel Lezcano <dlezcano@fr.ibm.com>
src/lxc/lxc-checkconfig.in

index 6ce79f420e2c034cc1f6a8a0ad0327030d36cce4..ab27b9cd17c5da9fce2ffc4b849813410811501c 100755 (executable)
@@ -74,7 +74,7 @@ echo "--- Misc ---"
 echo -n "Veth pair device: " && is_enabled CONFIG_VETH
 echo -n "Macvlan: " && is_enabled CONFIG_MACVLAN
 echo -n "Vlan: " && is_enabled CONFIG_VLAN_8021Q
-KVER_MINOR=$($GREP '^# Linux kernel version:' $CONFIG | \
+KVER_MINOR=$($GREP '^# Linux' $CONFIG | \
     sed -r 's/.*2.6.([0-9]{2}).*/\1/')
 echo -n "File capabilities: " &&
     [[ ${KVER_MINOR} < 33 ]] && is_enabled CONFIG_SECURITY_FILE_CAPABILITIES ||