diff options
author | Marc Espie <espie@cvs.openbsd.org> | 2014-06-17 13:35:07 +0000 |
---|---|---|
committer | Marc Espie <espie@cvs.openbsd.org> | 2014-06-17 13:35:07 +0000 |
commit | e2af69cba3ebd0ac988f7db6c81d31a76188babd (patch) | |
tree | a690a253b724e18fadc2dfded1be0561172b6259 /usr.sbin | |
parent | 8c954e1821cb7eba0cd960bab0a9552ccbf3731e (diff) |
oops, committed debug version, to the tied hash was not used at all,
and of course there were 3 obvious errors...
fixed and retested. much better now
Diffstat (limited to 'usr.sbin')
-rw-r--r-- | usr.sbin/pkg_add/OpenBSD/Add.pm | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/usr.sbin/pkg_add/OpenBSD/Add.pm b/usr.sbin/pkg_add/OpenBSD/Add.pm index ab1beb4a5ab..1737b5345b3 100644 --- a/usr.sbin/pkg_add/OpenBSD/Add.pm +++ b/usr.sbin/pkg_add/OpenBSD/Add.pm @@ -1,5 +1,5 @@ # ex:ts=8 sw=4: -# $OpenBSD: Add.pm,v 1.154 2014/06/16 09:02:07 espie Exp $ +# $OpenBSD: Add.pm,v 1.155 2014/06/17 13:35:06 espie Exp $ # # Copyright (c) 2003-2014 Marc Espie <espie@openbsd.org> # @@ -113,7 +113,7 @@ sub perform_extraction $state->{partial} = $handle->{partial}; $state->{archive} = $handle->{location}; $state->{check_digest} = $handle->{plist}{check_digest}; - my ($wanted, $tied) = {}; + my ($wanted, $tied) = ({}, {}); $handle->{plist}->find_extractible($state, $wanted, $tied); my $p = $state->progress->new_sizer($handle->{plist}, $state); while (my $file = $state->{archive}->next) { @@ -124,10 +124,11 @@ sub perform_extraction $state->{archive}->skip; $p->advance($e); # skip to next; + next; } $e = $wanted->{$file->name}; if (!defined $e) { - $state->Fatal("archive member not found #1", + $state->fatal("archive member not found #1", $file->name); } delete $wanted->{$file->name}; @@ -404,8 +405,6 @@ use OpenBSD::Temp; sub find_extractible { my ($self, $state, $wanted, $tied) = @_; - $wanted->{$self->name} = $self; - return; if ($self->{tied} || $self->{link} || $self->{symlink}) { $tied->{$self->name} = $self; } else { |