diff options
author | Olivier Blin <oblin@mandriva.org> | 2005-01-03 23:45:00 +0000 |
---|---|---|
committer | Olivier Blin <oblin@mandriva.org> | 2005-01-03 23:45:00 +0000 |
commit | 002fc172dd78b38485ab98082f5cbb136bb93469 (patch) | |
tree | 8af1c412990f1f4a78509b77d1a93312dc518e42 /urpmq | |
parent | cbe2fa9531333458597301441ba24764e7a9f4c2 (diff) | |
download | urpmi-002fc172dd78b38485ab98082f5cbb136bb93469.tar urpmi-002fc172dd78b38485ab98082f5cbb136bb93469.tar.gz urpmi-002fc172dd78b38485ab98082f5cbb136bb93469.tar.bz2 urpmi-002fc172dd78b38485ab98082f5cbb136bb93469.tar.xz urpmi-002fc172dd78b38485ab98082f5cbb136bb93469.zip |
fix virtual hdlist check (when fetching headers)
Diffstat (limited to 'urpmq')
-rwxr-xr-x | urpmq | 12 |
1 files changed, 5 insertions, 7 deletions
@@ -341,14 +341,12 @@ if ($urpm::args::options{list_aliases}) { map { my $pkg = $urpm->{depslist}[$_]; $pkg && $pkg->header_filename } @selected)) { - if (-s "$urpm->{statedir}/$urpm->{media}[$_]{hdlist}") { + my $hdlist_path = $urpm->{media}[$_]{virtual} + ? ("$urpm->{media}[$_]{url}/$urpm->{media}[$_]{with_hdlist}" =~ m!^(?:file:/*)?(/[^/].*)!)[0] + : "$urpm->{statedir}/$urpm->{media}[$_]{hdlist}"; + if (-s $hdlist_path) { require packdrake; - my $packer = new packdrake( - $urpm->{media}[$_]{virtual} - ? ("$urpm->{media}[$_]{url}/$urpm->{media}[$_]{with_hdlist}" =~ m!^(?:file:/*)?(/[^/].*)!)[0] - : "$urpm->{statedir}/$urpm->{media}[$_]{hdlist}", - quiet => 1, - ); + my $packer = new packdrake($hdlist_path, quiet => 1); $packer->extract_archive($tmp_header_dir, @headers); } elsif (!%downloads) { #- fallback to retrieve rpm package before, so that --headers will be ok. |