summaryrefslogtreecommitdiffstats
path: root/usr.sbin/sysinstall/msg.c
diff options
context:
space:
mode:
authorjkh <jkh@FreeBSD.org>1995-05-05 23:47:47 +0000
committerjkh <jkh@FreeBSD.org>1995-05-05 23:47:47 +0000
commit5d77b2037bd2957e492a7f71d3c5c24aa1acd977 (patch)
tree72d06abaf97eae38b135d8d052df7300f82c0063 /usr.sbin/sysinstall/msg.c
parent4577466eb8a6f81f81486ed5ae680e9b021dacfb (diff)
downloadFreeBSD-src-5d77b2037bd2957e492a7f71d3c5c24aa1acd977.zip
FreeBSD-src-5d77b2037bd2957e492a7f71d3c5c24aa1acd977.tar.gz
All the editors are finished. Now if I can just get a problem with libdisk
fixed, we should be able to fully set up the user's disk. Still to come with next commit: filesystem setup, distribution extraction, final configuration.
Diffstat (limited to 'usr.sbin/sysinstall/msg.c')
-rw-r--r--usr.sbin/sysinstall/msg.c24
1 files changed, 22 insertions, 2 deletions
diff --git a/usr.sbin/sysinstall/msg.c b/usr.sbin/sysinstall/msg.c
index 442a3c9..9c60c1d 100644
--- a/usr.sbin/sysinstall/msg.c
+++ b/usr.sbin/sysinstall/msg.c
@@ -4,7 +4,7 @@
* This is probably the last program in the `sysinstall' line - the next
* generation being essentially a complete rewrite.
*
- * $Id: msg.c,v 1.4 1995/05/04 19:48:16 jkh Exp $
+ * $Id: msg.c,v 1.3 1995/05/04 03:51:21 jkh Exp $
*
* Copyright (c) 1995
* Jordan Hubbard. All rights reserved.
@@ -177,6 +177,23 @@ msgConfirm(char *fmt, ...)
free(errstr);
}
+/* Put up a message in a popup information box */
+void
+msgNotify(char *fmt, ...)
+{
+ va_list args;
+ char *errstr;
+
+ errstr = (char *)malloc(FILENAME_MAX);
+ va_start(args, fmt);
+ vsnprintf(errstr, FILENAME_MAX, fmt, args);
+ va_end(args);
+ use_helpline(NULL);
+ use_helpfile(NULL);
+ dialog_notify(errstr);
+ free(errstr);
+}
+
/* Put up a message in a popup yes/no box and return 1 for YES, 0 for NO */
int
msgYesNo(char *fmt, ...)
@@ -211,7 +228,10 @@ msgGetInput(char *buf, char *fmt, ...)
va_end(args);
use_helpline(NULL);
use_helpfile(NULL);
- strcpy(input_buffer, buf);
+ if (buf)
+ strcpy(input_buffer, buf);
+ else
+ input_buffer[0] = '\0';
rval = dialog_inputbox("Value Required", errstr, -1, -1, input_buffer);
free(errstr);
if (!rval)
OpenPOWER on IntegriCloud