my $st1 = new Benchmark;
my $std = timediff($st1, $st0);
- debug( "Search took ".timestr($std) );
+ debug( "Search took ".timestr($std) ) if DEBUG;
}
my $suite_wording = $suites_enc eq "all" ? "all suites"
.'</th></tr>';
foreach my $result (sort { $a->[0] cmp $b->[0] } @results) {
my $file = shift @$result;
- $$page_content .= "<tr><td class=\"file\">$file</td><td>";
+ $$page_content .= "<tr><td class=\"file\">/$file</td><td>";
my %pkgs;
foreach (@$result) {
my ($pkg, $arch) = split /:/, $_;
my ($results, $kw, $nres, $reverses) = @_;
my ($key, $value) = ($kw, "");
- debug( "searchfile: kw=$kw", 1 );
+ debug( "searchfile: kw=$kw", 1 ) if DEBUG;
for (my $status = $reverses->seq($key, $value, R_CURSOR);
$status == 0;
$status = $reverses->seq( $key, $value, R_NEXT)) {
# FIXME: what's the most efficient "is prefix of" thingy? We only want to know
# whether $kw is or is not a prefix of $key
last unless index($key, $kw) == 0;
- debug( "found $key", 2 );
+ debug( "found $key", 2 ) if DEBUG;
my @hits = split /\0/o, $value;
push @$results, [ scalar reverse($key), @hits ];