]> git.donarmstrong.com Git - debbugs.git/commitdiff
pass through a binary-to-source cache
authorDon Armstrong <don@donarmstrong.com>
Tue, 2 Jan 2018 19:26:59 +0000 (11:26 -0800)
committerDon Armstrong <don@donarmstrong.com>
Tue, 2 Jan 2018 19:26:59 +0000 (11:26 -0800)
Debbugs/CGI/Pkgreport.pm
Debbugs/Status.pm

index e64300ad43cf8466ffd7614bae022ea79c98f020..6f29e9316263856f3ea5611dc857ae70b8381ba9 100644 (file)
@@ -350,12 +350,14 @@ sub pkg_htmlizebugs {
          push @{$exclude{$key}}, split /\s*,\s*/, $value;
      }
 
+     my $binary_to_source_cache = {};
      foreach my $bug (@bugs) {
          my %status = %{get_bug_status(bug=>$bug,
                                        (exists $param{dist}?(dist => $param{dist}):()),
                                        bugusertags => $param{bugusertags},
                                        (exists $param{version}?(version => $param{version}):()),
                                        (exists $param{arch}?(arch => $param{arch}):(arch => $config{default_architectures})),
+                                       binary_to_source_cache => $binary_to_source_cache,
                                       )};
          next unless %status;
          next if bug_filter(bug => $bug,
index 4b8d82e828f06687595ea11a45164a4bb907401d..197b188a6d02c393b084631143c5307e44f589b3 100644 (file)
@@ -1220,6 +1220,9 @@ sub get_bug_status {
                                          indicatesource => {type => BOOLEAN,
                                                             default => 1,
                                                            },
+                                         binary_to_source_cache => {type => HASHREF,
+                                                                    optional => 1,
+                                                                   },
                                         },
                              );
      my %status;
@@ -1254,6 +1257,8 @@ sub get_bug_status {
 
      $status{source} = binary_to_source(binary=>[split /\s*,\s*/, $status{package}],
                                        source_only => 1,
+                                       exists $param{binary_to_source_cache}?
+                                       (cache =>$param{binary_to_source_cache}):(),
                                       );
 
      $status{"package"} = 'unknown' if ($status{"package"} eq '');