From: Frank Lichtenheld Date: Mon, 20 Feb 2006 15:21:39 +0000 (+0000) Subject: in read_entry_simple, prefer real packages over virtual ones X-Git-Tag: switch-to-templates~102 X-Git-Url: https://git.deb.at/?a=commitdiff_plain;h=ae7fe4440b28ab29c329da886a063c3e74f034cf;p=deb%2Fpackages.git in read_entry_simple, prefer real packages over virtual ones --- diff --git a/lib/Packages/Search.pm b/lib/Packages/Search.pm index 1851c83..ba3b68c 100644 --- a/lib/Packages/Search.pm +++ b/lib/Packages/Search.pm @@ -370,12 +370,16 @@ sub read_entry_simple { my @data = split ( /\s/o, $_, 8 ); debug( "Considering entry ".join( ':', @data), 2); if ($data[1] eq $suite) { - if ($archives->{$data[0]}) { + if ($archives->{$data[0]} + && ($data[2] ne 'virtual')) { debug( "Using entry ".join( ':', @data), 2); return \@data; + } elsif ($archives->{$data[0]}) { + debug( "Virtual entry ".join( ':', @data), 2); + @data_fuzzy = @data; } elsif ($data[0] eq 'us') { debug( "Fuzzy entry ".join( ':', @data), 2); - @data_fuzzy = @data; + @data_fuzzy = @data unless @data_fuzzy; } } }