From b9b051eec5d23d3068ae51ca9c3d94d13db36999 Mon Sep 17 00:00:00 2001 From: Marc Espie Date: Thu, 6 Nov 2003 18:06:01 +0000 Subject: do not try to run the post-install script on an aborted pkg_add. --- usr.sbin/pkg_add/pkg_add | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'usr.sbin') diff --git a/usr.sbin/pkg_add/pkg_add b/usr.sbin/pkg_add/pkg_add index 5e101ae3fe1..36df74cee91 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.6 2003/11/06 18:04:10 espie Exp $ +# $OpenBSD: pkg_add,v 1.7 2003/11/06 18:06:00 espie Exp $ # # Copyright (c) 2003 Marc Espie. # @@ -256,7 +256,7 @@ sub really_add($) } $handle->close(); - if ($plist->has(INSTALL)) { + if ($plist->has(INSTALL) && !$interrupted) { print "Install script: $dir",INSTALL ,"$pkgname POST-INSTALL\n" if $opt_v or $opt_n; unless ($opt_n) { system($dir.INSTALL, $pkgname, "POST-INSTALL") == 0 or die "install script borked"; -- cgit v1.2.3