X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=scripts%2Fgen-indices;h=7a8670d96ffb8c69fe90e73185e78a156792183b;hb=b891e91a269d4fdf0655dc33ed9a5acd5ba90612;hp=ff269963541658a69e665a0c755b1bc59f2bbd4e;hpb=2daad1da7ca48238e3ae97f0d62a21062b797a18;p=debbugs.git diff --git a/scripts/gen-indices b/scripts/gen-indices index ff26996..7a8670d 100755 --- a/scripts/gen-indices +++ b/scripts/gen-indices @@ -20,6 +20,8 @@ use Pod::Usage; use File::stat; use List::Util qw(min); +use Debbugs::Common qw(make_list); + =head1 NAME gen-indices - Generates index files for the cgi scripts @@ -39,7 +41,7 @@ gen-indices - Generates index files for the cgi scripts =over -=itme B<--quick> +=item B<--quick> Only update changed bugs @@ -81,6 +83,7 @@ use Debbugs::Config qw(:config); use Debbugs::Common qw(getparsedaddrs getbugcomponent lockpid); use Debbugs::Status qw(readbug split_status_fields); use Debbugs::Log; +use Debbugs::UTF8 qw(encode_utf8_structure); chdir($config{spool_dir}) or die "chdir $config{spool_dir} failed: $!"; @@ -196,7 +199,7 @@ while (my $dir = shift @dirs) { next; } next if $stat->mtime < $time; - my $fdata = split_status_fields(readbug($bug, $initialdir)); + my ($fdata) = encode_utf8_structure(split_status_fields(readbug($bug, $initialdir))); $modification_made = 1; addbugtoindex("package", $bug, make_list($fdata->{package})); addbugtoindex("tag", $bug, make_list($fdata->{keywords}));