This is the mail archive of the libc-hacker@sourceware.org mailing list for the glibc project.
Note that libc-hacker is a closed list. You may look at the archives of this list, but subscription and posting are not open.
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
| Other format: | [Raw text] | |
Hi!
While it is generally a bad idea to run glibc testsuite as root (and I
usually don't do that either), other tests test for this condition too.
2006-01-15 Jakub Jelinek <jakub@redhat.com>
* io/tst-faccessat.c (do_test): Don't fail if getuid () == 0.
--- libc/io/tst-faccessat.c.jj 2006-01-06 13:14:18.000000000 +0100
+++ libc/io/tst-faccessat.c 2006-01-15 21:10:20.000000000 +0100
@@ -134,8 +134,9 @@ do_test (void)
}
errno = 0;
- if (faccessat (dir_fd, "some-file", W_OK, AT_EACCESS) == 0
- || errno != EACCES)
+ if (getuid () != 0
+ && (faccessat (dir_fd, "some-file", W_OK, AT_EACCESS) == 0
+ || errno != EACCES))
{
printf ("faccessat W_OK on unwritable file: %m\n");
result = 1;
Jakub
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |