testing: add full path for /sbin executables

"/sbin" might not be in the user's path, so prefix callouts to such
utilities with their full path.
This commit is contained in:
Joe Lawrence 2017-01-09 13:51:32 -05:00
parent f7b59ca809
commit 97be7f57fb
1 changed files with 2 additions and 2 deletions

View File

@ -120,12 +120,12 @@ log() {
}
unload_all() {
for i in `lsmod |egrep '^kpatch' |awk '{print $1}'`; do
for i in `/sbin/lsmod |egrep '^kpatch' |awk '{print $1}'`; do
if [[ $i != kpatch ]]; then
$KPATCH unload $i >> $LOG 2>&1 || error "\"kpatch unload $i\" failed"
fi
done
if lsmod |egrep -q '^kpatch'; then
if /sbin/lsmod |egrep -q '^kpatch'; then
$RMMOD kpatch >> $LOG 2>&1 || error "\"rmmod kpatch\" failed"
fi
}