]> code.ossystems Code Review - openembedded-core.git/commitdiff
systemd-systemctl-native: fix unit detection
authorRoss Burton <ross.burton@intel.com>
Wed, 6 Apr 2016 19:45:57 +0000 (20:45 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Fri, 8 Apr 2016 07:04:28 +0000 (08:04 +0100)
The regexs were too strict and didn't allow for trailing whitespace.

[ YOCTO #9337 ]

Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/recipes-core/systemd/systemd-systemctl/systemctl

index 1164dd4950b540bc557d9b88b88331a6fbe88f10..efad14ce17cf8ea1e76b659ba51922831d5d31a1 100755 (executable)
@@ -108,7 +108,7 @@ for service in $services; do
 
        # If any new unit types are added to systemd they should be added
        # to this regular expression.
-       unit_types_re='\.\(service\|socket\|device\|mount\|automount\|swap\|target\|path\|timer\|snapshot\)$'
+       unit_types_re='\.\(service\|socket\|device\|mount\|automount\|swap\|target\|path\|timer\|snapshot\)\s*$'
        if [ "$action" = "preset" ]; then
                action=`egrep -sh  $service $ROOT/etc/systemd/user-preset/*.preset | cut -f1 -d' '`
                if [ -z "$action" ]; then