summaryrefslogtreecommitdiff
path: root/usr.sbin
diff options
context:
space:
mode:
authorMarc Espie <espie@cvs.openbsd.org>2009-12-31 12:36:58 +0000
committerMarc Espie <espie@cvs.openbsd.org>2009-12-31 12:36:58 +0000
commitdd4e6ff643b80c29dbd4fd79230da576f17f7b1d (patch)
tree269b218a4e3181986459cb76c4510557c9abc703 /usr.sbin
parent1724b2ca06598371c4e6d25a00408d1aaa486a54 (diff)
XXX until I fix it for real
Diffstat (limited to 'usr.sbin')
-rw-r--r--usr.sbin/pkg_add/OpenBSD/ForwardDependencies.pm11
1 files changed, 8 insertions, 3 deletions
diff --git a/usr.sbin/pkg_add/OpenBSD/ForwardDependencies.pm b/usr.sbin/pkg_add/OpenBSD/ForwardDependencies.pm
index 5546bd930bd..4a1551b4efb 100644
--- a/usr.sbin/pkg_add/OpenBSD/ForwardDependencies.pm
+++ b/usr.sbin/pkg_add/OpenBSD/ForwardDependencies.pm
@@ -1,5 +1,5 @@
# ex:ts=8 sw=4:
-# $OpenBSD: ForwardDependencies.pm,v 1.4 2009/12/29 18:16:14 espie Exp $
+# $OpenBSD: ForwardDependencies.pm,v 1.5 2009/12/31 12:36:57 espie Exp $
#
# Copyright (c) 2009 Marc Espie <espie@openbsd.org>
#
@@ -45,8 +45,13 @@ sub adjust
for my $f (keys %{$self->{forward}}) {
my $deps_f = OpenBSD::Requiring->new($f);
for my $check ($deps_f->list) {
- if (defined $set->{older}->{$check}) {
- my $r = $set->{older}->{$check}->{update_found}->pkgname;
+ my $h = $set->{older}->{$check};
+ next unless defined $h;
+ if (!defined $h->{update_found}) {
+ $state->errsay("XXX $check");
+ $deps_f->delete($check);
+ } else {
+ my $r = $h->{update_found}->pkgname;
$state->say("Adjusting $check to $r in $f")
if $state->verbose >= 3;
if ($check ne $r) {