Change 33348 by [EMAIL PROTECTED] on 2008/02/22 17:56:12
Integrate:
[ 33274]
Make fs.t compare the permissions of a link with those
of the linked file rather than guessing at system defaults.
Affected files ...
... //depot/maint-5.10/perl/t/io/fs.t#2 integrate
Differences ...
==== //depot/maint-5.10/perl/t/io/fs.t#2 (xtext) ====
Index: perl/t/io/fs.t
--- perl/t/io/fs.t#1~32694~ 2007-12-22 01:23:09.000000000 -0800
+++ perl/t/io/fs.t 2008-02-22 09:56:12.000000000 -0800
@@ -87,7 +87,7 @@
close(FH);
my ($dev,$ino,$mode,$nlink,$uid,$gid,$rdev,$size,$atime,$mtime,$ctime,
- $blksize,$blocks);
+ $blksize,$blocks,$a_mode);
SKIP: {
skip("no link", 4) unless $has_link;
@@ -95,6 +95,8 @@
ok(link('a','b'), "link a b");
ok(link('b','c'), "link b c");
+ $a_mode = (stat('a'))[2];
+
($dev,$ino,$mode,$nlink,$uid,$gid,$rdev,$size,$atime,$mtime,$ctime,
$blksize,$blocks) = stat('c');
@@ -111,7 +113,9 @@
# if ($^O eq 'cygwin') { # new files on cygwin get rwx instead of rw-
# is($mode & 0777, 0777, "mode of triply-linked file");
# } else {
- is($mode & 0777, 0666, "mode of triply-linked file");
+ is(sprintf("0%o", $mode & 0777),
+ sprintf("0%o", $a_mode & 0777),
+ "mode of triply-linked file");
# }
}
}
End of Patch.