summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>2007-05-04 12:01:43 +0200
committerJim Meyering <jim@meyering.net>2007-05-04 12:01:43 +0200
commit3affac54ed4b0e2c3a2e0d350403b92a26a961b9 (patch)
treec4ac95b2b078378e5ddefc9cf12176fd7c333a44
parentab402c29f9bbb7b6b55482e848bcb320b9eb70b9 (diff)
downloadcoreutils-3affac54ed4b0e2c3a2e0d350403b92a26a961b9.tar.xz
Avoid failure of root-only test when run with a restrictive umask.
* tests/rm/no-give-up: Ensure that non-root can access "d/" through root-owned ".". Reported by AIDA Shinra.
-rw-r--r--ChangeLog4
-rwxr-xr-xtests/rm/no-give-up10
2 files changed, 10 insertions, 4 deletions
diff --git a/ChangeLog b/ChangeLog
index 5efd94b2f..bd1b30445 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,9 @@
2007-05-04 Jim Meyering <jim@meyering.net>
+ Avoid failure of root-only test when run with a restrictive umask.
+ * tests/rm/no-give-up: Ensure that non-root can access "d/" through
+ root-owned ".". Reported by AIDA Shinra.
+
tr -c: don't abort when translating with S2 larger than complement of S1
* src/tr.c (main): Remove invalid assertion triggered by e.g.,
tr -c a '[b*256]'. There's nothing wrong with having Set2 larger
diff --git a/tests/rm/no-give-up b/tests/rm/no-give-up
index dbd99eb14..d90e9e6dc 100755
--- a/tests/rm/no-give-up
+++ b/tests/rm/no-give-up
@@ -34,10 +34,12 @@ trap '(exit $?); exit $?' 1 2 13 15
framework_failure=0
mkdir -p $tmp || framework_failure=1
cd $tmp || framework_failure=1
-mkdir d
-touch d/f
-chown -R $NON_ROOT_USERNAME d
-chmod go= .
+mkdir d || framework_failure=1
+touch d/f || framework_failure=1
+chown -R $NON_ROOT_USERNAME d || framework_failure=1
+
+# Ensure that non-root can access files in root-owned ".".
+chmod go=x . || framework_failure=1
if test $framework_failure = 1; then
echo "$0: failure in testing framework" 1>&2