diff options
author | Marc Espie <espie@cvs.openbsd.org> | 2009-04-19 14:58:33 +0000 |
---|---|---|
committer | Marc Espie <espie@cvs.openbsd.org> | 2009-04-19 14:58:33 +0000 |
commit | ec8ddac0b1b2a0ba80424a1b47bb6bab9e35bcf5 (patch) | |
tree | d6cca43827cdc725b832e2a73bf959a6200d61f2 /usr.sbin/pkg_add/OpenBSD/PackageRepository.pm | |
parent | 087733393d1622a68046244a995781b5af3496b2 (diff) |
synch with my new style search/location changes
It's likely there will be some fallout, but it's getting a bit too large
to keep around.
This does kill a few very old oddities as well.
Diffstat (limited to 'usr.sbin/pkg_add/OpenBSD/PackageRepository.pm')
-rw-r--r-- | usr.sbin/pkg_add/OpenBSD/PackageRepository.pm | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/usr.sbin/pkg_add/OpenBSD/PackageRepository.pm b/usr.sbin/pkg_add/OpenBSD/PackageRepository.pm index 1e8d2fe7bc1..796e6260861 100644 --- a/usr.sbin/pkg_add/OpenBSD/PackageRepository.pm +++ b/usr.sbin/pkg_add/OpenBSD/PackageRepository.pm @@ -1,5 +1,5 @@ # ex:ts=8 sw=4: -# $OpenBSD: PackageRepository.pm,v 1.62 2009/02/02 20:41:47 espie Exp $ +# $OpenBSD: PackageRepository.pm,v 1.63 2009/04/19 14:58:32 espie Exp $ # # Copyright (c) 2003-2007 Marc Espie <espie@openbsd.org> # @@ -231,7 +231,9 @@ sub find my ($repository, $name, $arch) = @_; my $self = OpenBSD::PackageLocation->new($repository, $name, $arch); - return $self->openPackage; + if ($self->contents) { + return $self; + } } sub grabPlist @@ -482,7 +484,7 @@ sub open_pipe require OpenBSD::Temp; my ($self, $object) = @_; - $object->{errors} = OpenBSD::Temp::file(); + $object->{errors} = OpenBSD::Temp->file; $object->{cache_dir} = $ENV{'PKG_CACHE'}; $object->{parent} = $$; @@ -560,9 +562,6 @@ sub grab_object { my ($self, $object) = @_; my ($ftp, @extra) = split(/\s+/, OpenBSD::Paths->ftp); - if (defined $ENV{'FTP_KEEPALIVE'}) { - push(@extra, "-k", $ENV{'FTP_KEEPALIVE'}); - } exec {$ftp} $ftp, @extra, @@ -691,7 +690,7 @@ sub list my ($self) = @_; if (!defined $self->{list}) { $self->make_room; - my $error = OpenBSD::Temp::file(); + my $error = OpenBSD::Temp->file; $self->{list} = $self->obtain_list($error); $self->parse_problems($error); } |