summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--usr.sbin/pkg_add/OpenBSD/Replace.pm6
1 files changed, 5 insertions, 1 deletions
diff --git a/usr.sbin/pkg_add/OpenBSD/Replace.pm b/usr.sbin/pkg_add/OpenBSD/Replace.pm
index f62b21f7f27..372134586ae 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.63 2009/12/26 17:00:49 espie Exp $
+# $OpenBSD: Replace.pm,v 1.64 2009/12/27 15:32:20 espie Exp $
#
# Copyright (c) 2004-2006 Marc Espie <espie@openbsd.org>
#
@@ -309,10 +309,14 @@ sub is_set_safe
my $ok = 1;
for my $pkg ($set->older) {
+ next if defined $pkg->{exec_checked};
$ok = 0 unless can_old_package_be_replaced($pkg->plist, $state);
+ $pkg->{exec_checked} = 1;
}
for my $pkg ($set->newer) {
+ next if defined $pkg->{exec_checked};
$ok = 0 unless is_new_package_safe($pkg->plist, $state);
+ $pkg->{exec_checked} = 1;
}
return 1 if $ok;