cvsexportcommit: force crlf translation
authorDustin Spicuzza <dustin@virtualroadside.com>
Mon, 29 Apr 2019 21:58:47 +0000 (14:58 -0700)
committerJunio C Hamano <gitster@pobox.com>
Tue, 7 May 2019 09:23:27 +0000 (18:23 +0900)
When using cvsnt + msys + git, it seems like the output of cvs status
had \r\n in it, and caused the command to fail.

This fixes that.

Signed-off-by: Dustin Spicuzza <dustin@virtualroadside.com>
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
git-cvsexportcommit.perl
index d13f02da95f3b9b3921c3ccff9e3b6a7511cd666..fc00d5946af68e536876d42a1463b21924edefa5 100755 (executable)
@@ -431,6 +431,7 @@ END
 sub safe_pipe_capture {
     my @output;
     if (my $pid = open my $child, '-|') {
+       binmode($child, ":crlf");
        @output = (<$child>);
        close $child or die join(' ',@_).": $! $?";
     } else {