From ba8772e858d50f3c1fc2608b40f1228fee461c7a Mon Sep 17 00:00:00 2001 From: Russ Allbery Date: Mon, 29 May 2017 10:26:29 -0700 Subject: Fix some bugs in tools/policy-bug-report * Fix tools/policy-bug-report to not fail when bug lists are empty and to ignore closed bugs. --- tools/policy-bug-report | 2 ++ 1 file changed, 2 insertions(+) (limited to 'tools') diff --git a/tools/policy-bug-report b/tools/policy-bug-report index a9528a7..27da899 100755 --- a/tools/policy-bug-report +++ b/tools/policy-bug-report @@ -44,10 +44,12 @@ sub init_soap { # cannot handle usertags, only regular search criteria. sub print_bug_list { my ($soap, @criteria) = @_; + unshift (@criteria, status => 'open'); unshift (@criteria, package => 'debian-policy'); my $bugs = $soap->get_bugs (@criteria)->result; unless (@$bugs) { print "No bugs found\n"; + return; } my $info = $soap->get_status (@$bugs)->result; for my $bug (sort keys %$info) { -- cgit v1.2.3