summaryrefslogtreecommitdiffstats
path: root/usr.sbin/sysinstall/package.c
diff options
context:
space:
mode:
authorjkh <jkh@FreeBSD.org>1999-07-02 22:36:14 +0000
committerjkh <jkh@FreeBSD.org>1999-07-02 22:36:14 +0000
commit09d2fcf7ce9c557990687ca35240e537d4bd3ce3 (patch)
treebd8d251c407636bd37bfe867581ad952c8609cf5 /usr.sbin/sysinstall/package.c
parentf83d7679292bf0c56becaeb56d8fff81d2cec1c5 (diff)
downloadFreeBSD-src-09d2fcf7ce9c557990687ca35240e537d4bd3ce3.zip
FreeBSD-src-09d2fcf7ce9c557990687ca35240e537d4bd3ce3.tar.gz
Eliminate some varargs abuse.
Diffstat (limited to 'usr.sbin/sysinstall/package.c')
-rw-r--r--usr.sbin/sysinstall/package.c18
1 files changed, 13 insertions, 5 deletions
diff --git a/usr.sbin/sysinstall/package.c b/usr.sbin/sysinstall/package.c
index 7cc980e..4c311ae 100644
--- a/usr.sbin/sysinstall/package.c
+++ b/usr.sbin/sysinstall/package.c
@@ -4,7 +4,7 @@
* This is probably the last program in the `sysinstall' line - the next
* generation being essentially a complete rewrite.
*
- * $Id: package.c,v 1.76 1999/05/18 00:44:28 jkh Exp $
+ * $Id: package.c,v 1.77 1999/05/27 10:32:49 jkh Exp $
*
* Copyright (c) 1995
* Jordan Hubbard. All rights reserved.
@@ -218,8 +218,12 @@ package_extract(Device *dev, char *name, Boolean depended)
i = waitpid(pid, &tot, 0);
if (sigpipe_caught || i < 0 || WEXITSTATUS(tot)) {
ret = DITEM_FAILURE | DITEM_RESTORE;
- msgCNotify("Add of package %s aborted, error code %d -\n"
- "Please check the debug screen for more info.", name, WEXITSTATUS(tot));
+ if (variable_get(VAR_NO_CONFIRM))
+ msgNotify("Add of package %s aborted, error code %d -\n"
+ "Please check the debug screen for more info.", name, WEXITSTATUS(tot));
+ else
+ msgConfirm("Add of package %s aborted, error code %d -\n"
+ "Please check the debug screen for more info.", name, WEXITSTATUS(tot));
}
else
msgNotify("Package %s was added successfully", name);
@@ -233,8 +237,12 @@ package_extract(Device *dev, char *name, Boolean depended)
}
else {
dialog_clear_norefresh();
- msgCNotify("Unable to fetch package %s from selected media.\n"
- "No package add will be done.", name);
+ if (variable_get(VAR_NO_CONFIRM))
+ msgNotify("Unable to fetch package %s from selected media.\n"
+ "No package add will be done.", name);
+ else
+ msgConfirm("Unable to fetch package %s from selected media.\n"
+ "No package add will be done.", name);
ret = DITEM_FAILURE | DITEM_RESTORE;
}
signal(SIGPIPE, SIG_IGN);
OpenPOWER on IntegriCloud