From fbd6333a2747daa8c6680c2f309b73ccdac6ad5b Mon Sep 17 00:00:00 2001 From: espie Date: Fri, 12 Aug 2016 11:17:37 +0000 Subject: [PATCH] band-aid for a nasty bug. tieto + space constraints don't interact well. there are better fixes (such as computing tieto first, computing the size better, and doing two passes deletes), but at least this one doesn't fuck things up. --- usr.sbin/pkg_add/OpenBSD/Add.pm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/usr.sbin/pkg_add/OpenBSD/Add.pm b/usr.sbin/pkg_add/OpenBSD/Add.pm index 96f38dce79e..9b7f174dfcc 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.170 2016/04/02 12:18:44 espie Exp $ +# $OpenBSD: Add.pm,v 1.171 2016/08/12 11:17:37 espie Exp $ # # Copyright (c) 2003-2014 Marc Espie # @@ -420,7 +420,8 @@ use OpenBSD::Temp; sub find_extractible { my ($self, $state, $wanted, $tied) = @_; - if ($self->{tieto} || $self->{link} || $self->{symlink}) { + if ($self->{tieto} && !$state->{delete_first} + || $self->{link} || $self->{symlink}) { $tied->{$self->name} = $self; } else { $wanted->{$self->name} = $self; -- 2.20.1