summaryrefslogtreecommitdiff
path: root/usr.sbin/pkg_add
diff options
context:
space:
mode:
authorMarc Espie <espie@cvs.openbsd.org>2007-05-27 22:34:25 +0000
committerMarc Espie <espie@cvs.openbsd.org>2007-05-27 22:34:25 +0000
commit8756806e88157acbf137829b65075261b8955a01 (patch)
tree69970dad1621ad03e8b60bc497cd2ee58ddcc294 /usr.sbin/pkg_add
parent5f95645341c1e5c8b2c77756fb94a54ff5b70d4f (diff)
oops, save_old_libs is now set dependent, we no longer store old packages
in the same location.
Diffstat (limited to 'usr.sbin/pkg_add')
-rw-r--r--usr.sbin/pkg_add/OpenBSD/Replace.pm8
-rw-r--r--usr.sbin/pkg_add/pkg_add4
2 files changed, 7 insertions, 5 deletions
diff --git a/usr.sbin/pkg_add/OpenBSD/Replace.pm b/usr.sbin/pkg_add/OpenBSD/Replace.pm
index 8ce1a6cad0f..d5e863e6056 100644
--- a/usr.sbin/pkg_add/OpenBSD/Replace.pm
+++ b/usr.sbin/pkg_add/OpenBSD/Replace.pm
@@ -1,5 +1,5 @@
# ex:ts=8 sw=4:
-# $OpenBSD: Replace.pm,v 1.20 2007/05/27 21:43:06 espie Exp $
+# $OpenBSD: Replace.pm,v 1.21 2007/05/27 22:34:24 espie Exp $
#
# Copyright (c) 2004-2006 Marc Espie <espie@openbsd.org>
#
@@ -359,9 +359,11 @@ sub walk_depends_closure
sub save_old_libraries
{
- my ($new_plist, $state) = @_;
+ my ($set, $state) = @_;
- for my $old_plist (@{$new_plist->{replacing}}) {
+ my $new_plist = $set->handle->{plist};
+
+ for my $old_plist ($set->actual_replacements) {
my $libs = {};
my $p = {};
diff --git a/usr.sbin/pkg_add/pkg_add b/usr.sbin/pkg_add/pkg_add
index cbdfefd020c..d5b7d7fdbca 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.281 2007/05/27 22:18:14 espie Exp $
+# $OpenBSD: pkg_add,v 1.282 2007/05/27 22:34:24 espie Exp $
#
# Copyright (c) 2003-2007 Marc Espie <espie@openbsd.org>
#
@@ -364,7 +364,7 @@ sub really_add
OpenBSD::ProgressMeter::set_header("$pkgname (extracting)");
- OpenBSD::Replace::save_old_libraries($plist, $state);
+ OpenBSD::Replace::save_old_libraries($set, $state);
my $donesize = 0;
$plist->{done} = [];