diff options
author | Francois-Xavier Coudert <coudert@clipper.ens.fr> | 2006-08-12 03:03:29 +0200 |
---|---|---|
committer | François-Xavier Coudert <fxcoudert@gcc.gnu.org> | 2006-08-12 01:03:29 +0000 |
commit | a30701cf3e7226ec22973fa60d0eb06529d71155 (patch) | |
tree | c181625b768c8456f7bd76c805a96268a17994b1 /gcc | |
parent | 57868b141b27917f837377350731edcc4b59a71d (diff) | |
download | gcc-a30701cf3e7226ec22973fa60d0eb06529d71155.zip gcc-a30701cf3e7226ec22973fa60d0eb06529d71155.tar.gz gcc-a30701cf3e7226ec22973fa60d0eb06529d71155.tar.bz2 |
stat_1.f90: Make test pass when run under sudo.
* gfortran.dg/stat_1.f90: Make test pass when run under sudo.
* gfortran.dg/stat_2.f90: Likewise.
* gfortran.dg/chmod_1.f90: Likewise.
* gfortran.dg/chmod_2.f90: Likewise.
* gfortran.dg/chmod_3.f90: Likewise.
From-SVN: r116097
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/testsuite/ChangeLog | 8 | ||||
-rw-r--r-- | gcc/testsuite/gfortran.dg/chmod_1.f90 | 2 | ||||
-rw-r--r-- | gcc/testsuite/gfortran.dg/chmod_2.f90 | 2 | ||||
-rw-r--r-- | gcc/testsuite/gfortran.dg/chmod_3.f90 | 2 | ||||
-rw-r--r-- | gcc/testsuite/gfortran.dg/stat_1.f90 | 2 | ||||
-rw-r--r-- | gcc/testsuite/gfortran.dg/stat_2.f90 | 2 |
6 files changed, 13 insertions, 5 deletions
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 002761d..d7cb8c8 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,11 @@ +2006-08-12 Francois-Xavier Coudert <coudert@clipper.ens.fr> + + * gfortran.dg/stat_1.f90: Make test pass when run under sudo. + * gfortran.dg/stat_2.f90: Likewise. + * gfortran.dg/chmod_1.f90: Likewise. + * gfortran.dg/chmod_2.f90: Likewise. + * gfortran.dg/chmod_3.f90: Likewise. + 2006-08-11 David Edelsohn <edelsohn@gnu.org> * gfortran.dg/direct_io_6.f90: Skip on *-*-aix*. diff --git a/gcc/testsuite/gfortran.dg/chmod_1.f90 b/gcc/testsuite/gfortran.dg/chmod_1.f90 index e9ea27f..2f0af8c 100644 --- a/gcc/testsuite/gfortran.dg/chmod_1.f90 +++ b/gcc/testsuite/gfortran.dg/chmod_1.f90 @@ -20,7 +20,7 @@ end if call chmod (n, "a-w", i) - if (i == 0) then + if (i == 0 .and. getuid() /= 0) then if (access(n,"w") == 0 .or. access(n,"W") == 0) call abort end if diff --git a/gcc/testsuite/gfortran.dg/chmod_2.f90 b/gcc/testsuite/gfortran.dg/chmod_2.f90 index e413fca..3dc445e 100644 --- a/gcc/testsuite/gfortran.dg/chmod_2.f90 +++ b/gcc/testsuite/gfortran.dg/chmod_2.f90 @@ -20,7 +20,7 @@ end if i = chmod (n, "a-w") - if (i == 0) then + if (i == 0 .and. getuid() /= 0) then if (access(n,"w") == 0 .or. access(n,"W") == 0) call abort end if diff --git a/gcc/testsuite/gfortran.dg/chmod_3.f90 b/gcc/testsuite/gfortran.dg/chmod_3.f90 index 4ea34eb..cfeba67 100644 --- a/gcc/testsuite/gfortran.dg/chmod_3.f90 +++ b/gcc/testsuite/gfortran.dg/chmod_3.f90 @@ -20,7 +20,7 @@ end if i = chmod (n, "a-w") - if (i == 0) then + if (i == 0 .and. getuid() /= 0) then if (access(n,"w") == 0 .or. access(n,"W") == 0) call abort end if diff --git a/gcc/testsuite/gfortran.dg/stat_1.f90 b/gcc/testsuite/gfortran.dg/stat_1.f90 index c8e3881..5325634 100644 --- a/gcc/testsuite/gfortran.dg/stat_1.f90 +++ b/gcc/testsuite/gfortran.dg/stat_1.f90 @@ -15,7 +15,7 @@ if (r1 /= 0 .or. r2 /= 0 .or. r3 /= 0) call abort if (any (s1 /= s2) .or. any (s1 /= s3)) call abort if (s1(5) /= getuid()) call abort - if (s1(6) /= getgid()) call abort + if (s1(6) /= getgid() .and. getgid() /= 0) call abort if (s1(8) < 3 .or. s1(8) > 5) call abort close (10,status="delete") diff --git a/gcc/testsuite/gfortran.dg/stat_2.f90 b/gcc/testsuite/gfortran.dg/stat_2.f90 index 7ebd057..4bd17ca 100644 --- a/gcc/testsuite/gfortran.dg/stat_2.f90 +++ b/gcc/testsuite/gfortran.dg/stat_2.f90 @@ -15,7 +15,7 @@ if (r1 /= 0 .or. r2 /= 0 .or. r3 /= 0) call abort if (any (s1 /= s2) .or. any (s1 /= s3)) call abort if (s1(5) /= getuid()) call abort - if (s1(6) /= getgid()) call abort + if (s1(6) /= getgid() .and. getgid() /= 0) call abort if (s1(8) < 3 .or. s1(8) > 5) call abort close (10,status="delete") |