From: cjwatson <> Date: Thu, 22 May 2003 03:55:13 +0000 (-0800) Subject: [project @ 2003-05-21 20:55:13 by cjwatson] X-Git-Tag: release/2.6.0~908 X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=803e4fa0b1e562cd7a9552ed741b76899a4b0f55;p=debbugs.git [project @ 2003-05-21 20:55:13 by cjwatson] repeatmerged=no now does the right thing if the first in the set of merged bugs isn't in the current query (which can happen for by-submitter queries; see #167146). --- diff --git a/cgi/common.pl b/cgi/common.pl index 4f51ca0..c7662c4 100644 --- a/cgi/common.pl +++ b/cgi/common.pl @@ -348,11 +348,10 @@ sub htmlizebugs { } else { @bugs = sort {$a<=>$b} @bugs; } + my %seenmerged; foreach my $bug (@bugs) { my %status = %{getbugstatus($bug)}; next unless %status; - my @merged = sort {$a<=>$b} ($bug, split(/ /, $status{mergedwith})); - next unless ($common_repeatmerged || $bug == $merged[0]); if (%common_include) { my $okay = 0; foreach my $t (split /\s+/, $status{tags}) { @@ -384,6 +383,10 @@ sub htmlizebugs { next if grep { $_ eq $status{pending} } @common_pending_exclude; next if grep { $_ eq $status{severity} } @common_severity_exclude; + my @merged = sort {$a<=>$b} ($bug, split(/ /, $status{mergedwith})); + next unless ($common_repeatmerged || !$seenmerged{$merged[0]}); + $seenmerged{$merged[0]} = 1; + my $html = sprintf "
  • #%d: %s\n
    ", bugurl($bug), $bug, htmlsanit($status{subject}); $html .= htmlindexentrystatus(\%status) . "\n";