mirror of
https://github.com/RsyncProject/rsync.git
synced 2026-10-24 22:58:16 -04:00
Improved check_perms() to work with a directory, to have better
output on error, and to call test_fail on error.
This commit is contained in:
1 parent
fdbe8989fe
commit
eace352b39
1 file changed
+7
-1
+7
-1
@@ -70,7 +70,13 @@ rsync_ls_lR() {
|
||||
}
|
||||
|
||||
check_perms() {
|
||||
"$TOOLDIR/tls" "$1" | grep "^-$2" >/dev/null
|
||||
perms=`"$TOOLDIR/tls" "$1" | sed 's/^[-d]\(.........\).*/\1/'`
|
||||
if test $perms = $2; then
|
||||
return 0
|
||||
fi
|
||||
echo "permissions: $perms on $1"
|
||||
echo "should be: $2"
|
||||
test_fail "failed test $3"
|
||||
}
|
||||
|
||||
rsync_getgroups() {
|
||||
|
||||
Reference in new issue
Block a user