Perl 5.8.6 upgrade
Anton Berezin
tobez at FreeBSD.org
Fri Feb 4 00:59:38 PST 2005
On Fri, Feb 04, 2005 at 01:27:50AM +0100, Anton Berezin wrote:
> Please test.
> # $Id: perl-after-upgrade,v 1.6 2005/02/04 00:24:43 tobez Exp $
There is actually a file permission bug in the script. The following
patch fixes that:
Index: perl-after-upgrade
===================================================================
RCS file: /home/tobez/.local./cvs/FreeBSD-perl-tools/perl-after-upgrade,v
retrieving revision 1.6
diff -u -r1.6 perl-after-upgrade
--- perl-after-upgrade 4 Feb 2005 00:24:43 -0000 1.6
+++ perl-after-upgrade 4 Feb 2005 08:57:34 -0000
@@ -285,6 +285,7 @@
close $fh;
$new_md5 = `/sbin/md5 -q $fn`;
chomp $new_md5;
+ my $mode = (stat($file))[2] & 07777;
unlink $file or do {
push @errors, "Failed to unlink $file: $!";
unlink $fn;
@@ -294,6 +295,7 @@
push @errors, "Failed to rename $fn to $file: $!";
return "";
};
+ chmod $mode, $file;
} else {
push @errors, "Failed to modify $file: $!";
}
\Anton.
--
The moronity of the universe is a monotonically increasing function. --
Jarkko Hietaniemi
More information about the freebsd-perl
mailing list