Date: Fri, 4 Feb 2005 09:59:34 +0100 From: Anton Berezin <tobez@FreeBSD.org> To: Daren Desjardins <desjardins@canada.com> Cc: freebsd-perl@freebsd.org Subject: Re: Perl 5.8.6 upgrade Message-ID: <20050204085934.GA52914@heechee.tobez.org> In-Reply-To: <20050204002750.GA38458@heechee.tobez.org> References: <4200F3B3.7050706@canada.com> <813911377.1107434232.147437664.80111@mcgi2.rambler.ru> <20050203124845.GD15084@heechee.tobez.org> <420235E6.3030206@canada.com> <20050204002750.GA38458@heechee.tobez.org>
next in thread | previous in thread | raw e-mail | index | archive | help
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
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20050204085934.GA52914>
