summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorespie <espie@openbsd.org>2014-02-10 19:16:19 +0000
committerespie <espie@openbsd.org>2014-02-10 19:16:19 +0000
commit64d38bd30d2cb923caeb00d09e4d15980d46190b (patch)
tree43e19c47e92dfbce1b0a72a54afe6e3335e3f54c
parentcvstags are a bit fickle, there's no need to always-update if they change. (diff)
downloadwireguard-openbsd-64d38bd30d2cb923caeb00d09e4d15980d46190b.tar.xz
wireguard-openbsd-64d38bd30d2cb923caeb00d09e4d15980d46190b.zip
assume tweaking package status always work if $state->{not}.
Problem noticed by Mikolaj Kucharski
-rw-r--r--usr.sbin/pkg_add/OpenBSD/Add.pm3
1 files changed, 2 insertions, 1 deletions
diff --git a/usr.sbin/pkg_add/OpenBSD/Add.pm b/usr.sbin/pkg_add/OpenBSD/Add.pm
index 000a35c6978..cad7a6e9ac9 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.148 2014/02/08 10:43:25 espie Exp $
+# $OpenBSD: Add.pm,v 1.149 2014/02/10 19:16:19 espie Exp $
#
# Copyright (c) 2003-2014 Marc Espie <espie@openbsd.org>
#
@@ -143,6 +143,7 @@ sub tweak_package_status
$pkgname = extract_pkgname($pkgname);
return 0 unless is_installed($pkgname);
return 0 unless $user_tagged->{$pkgname};
+ return 1 if $state->{not};
my $plist = OpenBSD::PackingList->from_installation($pkgname);
if ($plist->has('manual-installation') && $state->{automatic} > 1) {
delete $plist->{'manual-installation'};