summaryrefslogtreecommitdiff
path: root/usr.sbin/pkg_add
diff options
context:
space:
mode:
authorMarc Espie <espie@cvs.openbsd.org>2006-02-10 11:42:52 +0000
committerMarc Espie <espie@cvs.openbsd.org>2006-02-10 11:42:52 +0000
commitbedb4609ffe1d8813ab1b57de8296473771f636a (patch)
treea11dd802d7ff01a777353138e252078f08c7e6e3 /usr.sbin/pkg_add
parentddc125389005bf18d72bde61e4a81e5419bc08ba (diff)
reset $state->{dir} to the correct value after deleting the replaced package.
Fixes a problem noticed by steven.
Diffstat (limited to 'usr.sbin/pkg_add')
-rw-r--r--usr.sbin/pkg_add/pkg_add3
1 files changed, 2 insertions, 1 deletions
diff --git a/usr.sbin/pkg_add/pkg_add b/usr.sbin/pkg_add/pkg_add
index 68856036fb3..61d3309c98a 100644
--- a/usr.sbin/pkg_add/pkg_add
+++ b/usr.sbin/pkg_add/pkg_add
@@ -1,7 +1,7 @@
#! /usr/bin/perl
# ex:ts=8 sw=4:
-# $OpenBSD: pkg_add,v 1.215 2006/02/10 10:08:16 bernd Exp $
+# $OpenBSD: pkg_add,v 1.216 2006/02/10 11:42:51 espie Exp $
#
# Copyright (c) 2003-2004 Marc Espie <espie@openbsd.org>
#
@@ -371,6 +371,7 @@ sub really_add($$)
# Here there should be code to handle old libs
OpenBSD::ProgressMeter::set_header("$pkgname (installing)");
+ $state->{dir} = $plist->{dir};
$state->set_pkgname($pkgname);
}