globtest.sh
Jakub Jelinek
jakub@redhat.com
Mon Apr 10 07:43:00 GMT 2000
On Mon, Apr 10, 2000 at 04:38:30PM +0200, Andreas Schwab wrote:
> The "noread" glob tests in 2.2 cannot be run as root since root can read
> everything. That should be handled gracefully.
>
> Andreas.
>
> 2000-04-10 Andreas Schwab <schwab@suse.de>
>
> * posix/globtest.sh: Skip tests that depend on unreadable
> directories if run as root.
>
> Index: posix/globtest.sh
> ===================================================================
> RCS file: /cvs/glibc/libc/posix/globtest.sh,v
> retrieving revision 1.11
> diff -u -a -u -r1.11 posix/globtest.sh
> --- posix/globtest.sh 2000/03/20 00:45:09 1.11
> +++ posix/globtest.sh 2000/04/10 14:34:51
> @@ -306,6 +306,9 @@
> GLOB_NOMATCH
> EOF
>
> +# The following tests will fail if run as root.
> +if test "`id -un`" != root; then
> +
> # ... with GLOB_ERR
> ${elf_objpfx}${rtld_installed_name} --library-path ${library_path} \
> ${common_objpfx}posix/globtest -E "$testdir" "noread/*" |
> @@ -320,6 +323,8 @@
> cat <<"EOF" | cmp - $testout || result=1
> GLOB_ABORTED
> EOF
> +
> +endif # not run as root
^^^^^ ??
Shouldn't it be
fi # not run as root
?
Jakub
More information about the Libc-hacker
mailing list