X-Git-Url: https://git.donarmstrong.com/?p=bugscan.git;a=blobdiff_plain;f=bugreport;h=49bcc929a05a1abbec2af76efb3de7ebbba058f6;hp=22f4775cc3df22b417109e4276de9a760c6e8610;hb=8fdaf19c4b53bfa22da01dfb2048ec20a6e6767f;hpb=a00f1a19cc83ae763213278b462bace11f29a7b1 diff --git a/bugreport b/bugreport index 22f4775..49bcc92 100755 --- a/bugreport +++ b/bugreport @@ -135,11 +135,15 @@ sub MakeStatistics() { my $worrytotal=0; # Total number of bugs we're actually worried about my $stabletotal=0; # Total number of bugs affecting stable my %list; # List of bugnumber associated with package + my %seen_bugs; # bugs which have already been counted for my $p (sort keys %scanlib::packagelist) { my $count = 0; # Number of bugs for this package for my $nr (@{$scanlib::packagelist{$p}}) { + # if we've already counted this bug, we don't want to count it again + next if $seen_bugs{$nr}; + $seen_bugs{$nr} = 1; $pendingtotal++ if ($scanlib::bugs{$nr}->{'pending'}); $patchtotal++ if ($scanlib::bugs{$nr}->{'patch'}); $ignoretotal++ if ($scanlib::bugs{$nr}->{'wheezy-ignore'} || $scanlib::bugs{$nr}->{'squeeze-ignore'}); @@ -152,12 +156,12 @@ sub MakeStatistics() { } if ($html) { - print "Total number of release-critical bugs: $bugcount
\n"; + print "Total number of release-critical bugs: $bugcount
\n"; printf("Number that have a patch: %d
\n", $patchtotal); printf("Number that have a fix prepared and waiting to upload: %d
\n", $pendingtotal); printf("Number that are being ignored: %d
\n", $ignoretotal); - printf("Number concerning the current stable release: %d
\n", $stabletotal); - printf("Number concerning the next release: %d

\n", $worrytotal); + printf("Number concerning the current stable release: %d
\n", $stabletotal); + printf("Number concerning the next release: %d

\n", $worrytotal); } else { print "Total number of release-critical bugs: $bugcount\n"; printf("Number that have a patch: %d\n", $patchtotal);