Skip to content

Commit 37d117f

Browse files
FANG.Geoberpar
authored andcommitted
geninfo: support remove CR endings of old intermediate text
On mingw gcc toolkits, gcov outputs with CRLF, if CRs are not removed, filenames with CR control charaters cannot be used to read file correctly. Fix this by explicitly removing CR+LF. [oberpar: Minor commit message changes] Signed-off-by: FANG.Ge <[email protected]>
1 parent 8c34f13 commit 37d117f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

bin/geninfo

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2128,7 +2128,7 @@ sub read_intermediate_text($$)
21282128
while (my $line = <$fd>) {
21292129
if ($line =~ /^file:(.*)$/) {
21302130
$filename = $1;
2131-
chomp($filename);
2131+
$filename =~ s/[\r\n]$//g;
21322132
} elsif (defined($filename)) {
21332133
$data->{$filename} .= $line;
21342134
}

0 commit comments

Comments
 (0)