Skip to content

Commit

Permalink
lcov
Browse files Browse the repository at this point in the history
- minor fix for regular expression used to parse .gcov files - caused
  problems when parsing branch coverage data and when using custom
  gcov versions
  • Loading branch information
Peter Oberparleiter authored and oberpar committed Jun 10, 2014
1 parent ce6335e commit 47943ee
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions bin/geninfo
Expand Up @@ -997,7 +997,7 @@ sub read_gcov_file($)
{
chomp($_);

if (/^branch\s+\d+\s+(\S+)\s+(\S+)$/)
if (/^branch\s+\d+\s+(\S+)\s+(\S+)/)
{
# Branch execution data
push(@branches, scalar(@result) / 3);
Expand All @@ -1018,7 +1018,7 @@ sub read_gcov_file($)
{
# Function call return data
}
elsif (/^\s*([^:\s]+):\s*([^:\s]+):(.*)$/)
elsif (/^\s*([^:]+):\s*([^:]+):(.*)$/)
{
# <exec count>:<line number>:<source code>
if ($2 eq "0")
Expand Down

0 comments on commit 47943ee

Please sign in to comment.