diff options
author | Jim Meyering <jim@meyering.net> | 2002-07-20 05:36:59 +0000 |
---|---|---|
committer | Jim Meyering <jim@meyering.net> | 2002-07-20 05:36:59 +0000 |
commit | 39d971818e17babbb9387d5c1463c19620f71144 (patch) | |
tree | d0ecef5eff9b7bb588b3ab06a69ce1c50a6aa3a4 | |
parent | e724268ea5cd3679bac06291f46dfbd26b115072 (diff) | |
download | coreutils-39d971818e17babbb9387d5c1463c19620f71144.tar.xz |
skip directories, too.
Otherwise, we'd have to account for the additional `directory ' part
of a diagnostic like this:
fail-eperm: unexpected dignostic from `rm -f /tmp/.pcmcia';
got rm: cannot remove directory `/tmp/.pcmcia': Is a directory
expected rm: cannot remove `/tmp/.pcmcia': ...
-rwxr-xr-x | tests/rm/fail-eperm | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/rm/fail-eperm b/tests/rm/fail-eperm index fd9c7e157..a5eb4c18a 100755 --- a/tests/rm/fail-eperm +++ b/tests/rm/fail-eperm @@ -52,9 +52,9 @@ foreach my $dir (@dir_list) foreach my $f (readdir DIR_HANDLE) { - # Skip files owned by self, and symlinks. + # Skip files owned by self, symlinks, and directories. # It's not technically necessary to skip symlinks, but it's simpler. - -l $f || -o _ + -l $f || -o _ || -d _ and next; $found_file = 1; |