Commit 179515a6 authored by Sergei Golubchik's avatar Sergei Golubchik

bugfix: dgcov.pl shows wrong line numbers

dgcov.pl was putting gcov execution counters on wrong lines
in the report (*.dgcov files were correct), because it was
incrementing the new line number for diff lines starting from '-'
(lines from the old file, not present in the new)
parent 4f5dea43
......@@ -112,8 +112,7 @@ sub print_gcov_for_diff {
$acc.=sprintf '%9s:%5s:%s', '', $lnum, $' if /^ /;
++$printme, $acc.=sprintf '%9s:%5s:%s', gcov_prefix($fcov->{$lnum}), $lnum, $' if /^\+/;
die "$_^^^ dying", unless /^[- +]/;
++$lnum;
--$cnt;
++$lnum, --$cnt unless /^-/;
}
print $acc if $printme;
close PIPE or die "command '$cmd' failed: $!: $?";
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment