From: Steve Hay Date: Sat, 20 Feb 2010 16:22:41 +0000 (+0000) Subject: Stop Porting/bump-perl-version from changing EOLs on Win32 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=33c1015fda04899ea576248c4c328da8ad24e12c;p=p5sagit%2Fp5-mst-13.2.git Stop Porting/bump-perl-version from changing EOLs on Win32 --- diff --git a/Porting/bump-perl-version b/Porting/bump-perl-version index c460ad4..b0e77a8 100755 --- a/Porting/bump-perl-version +++ b/Porting/bump-perl-version @@ -293,6 +293,7 @@ sub do_update { my %contents; for my $file (sort keys %changes) { open my $fh, '<', $file or die "open '$file': $!\n"; + binmode $fh; $contents{$file} = [ <$fh> ]; chomp @{$contents{$file}}; close $fh or die "close: '$file': $!\n"; @@ -323,6 +324,7 @@ sub do_update { for my $file (sort keys %contents) { my $nfile = "$file-new"; open my $fh, '>', $nfile or die "create '$nfile' failed: $!\n"; + binmode $fh; print $fh $_, "\n" for @{$contents{$file}}; close $fh or die "failed to close $nfile; aborting: $!\n";