Merge Quote some variables in regression test suite to allow for spaces

This is not a complete fix for the spaces issue, but it is the next simple step that can be taken before the more difficult work of finding the remaining bugs in each shell script.

Signed-off-by: Ryan Lee <ryan.lee@canonical.com>

MR: https://gitlab.com/apparmor/apparmor/-/merge_requests/1424
Approved-by: Christian Boltz <apparmor@cboltz.de>
Merged-by: Christian Boltz <apparmor@cboltz.de>
This commit is contained in:
Christian Boltz 2024-11-18 21:30:46 +00:00
commit e27b0ad2b6

View file

@ -201,7 +201,7 @@ exit_handler()
# global bin # global bin
if [ -d "$bin" ] if [ -d "$bin" ]
then then
. $bin/epilogue.inc . "$bin/epilogue.inc"
fi fi
} }
@ -403,7 +403,7 @@ emit_profile()
name=$1; shift 1 name=$1; shift 1
$bin/mkprofile.pl ${mkflags} "$name" ${outfile}:w "$@" >> $profile "$bin/mkprofile.pl" ${mkflags} "$name" ${outfile}:w "$@" >> $profile
echo $name >> $profilenames echo $name >> $profilenames
} }
@ -537,7 +537,7 @@ loadprofile()
{ {
#global complainflaf profile profileloaded #global complainflaf profile profileloaded
$subdomain ${parser_args} $complainflag $profile > /dev/null "$subdomain" ${parser_args} $complainflag $profile > /dev/null
if [ $? -ne 0 ] if [ $? -ne 0 ]
then then
removeprofile removeprofile
@ -551,7 +551,7 @@ replaceprofile()
{ {
#global complainflag profile #global complainflag profile
$subdomain ${parser_args} -r $complainflag $profile > /dev/null "$subdomain" ${parser_args} -r $complainflag $profile > /dev/null
if [ $? -ne 0 ] if [ $? -ne 0 ]
then then
fatalerror "Unable to replace profile $profile" fatalerror "Unable to replace profile $profile"
@ -570,7 +570,7 @@ removeprofile()
remprofile=$profile remprofile=$profile
fi fi
$subdomain ${parser_args} -R $remprofile > /dev/null "$subdomain" ${parser_args} -R $remprofile > /dev/null
if [ $? -ne 0 ] if [ $? -ne 0 ]
then then
fatalerror "Unable to remove profile $remprofile" fatalerror "Unable to remove profile $remprofile"
@ -685,9 +685,9 @@ else
fi fi
# load user changeable variables # load user changeable variables
. $bin/uservars.inc . "$bin/uservars.inc"
if [ ! -x $subdomain ] if [ ! -x "$subdomain" ]
then then
fatalerror "AppArmor parser '$subdomain' is not executable" fatalerror "AppArmor parser '$subdomain' is not executable"
fi fi