summaryrefslogtreecommitdiffstats
path: root/usr.sbin/sysinstall/tcpip.c
diff options
context:
space:
mode:
authorjkh <jkh@FreeBSD.org>1999-05-07 11:45:26 +0000
committerjkh <jkh@FreeBSD.org>1999-05-07 11:45:26 +0000
commitc1afe7bbe25d479fb86ffe597401929339c59395 (patch)
treea6d3e2fef42f07af333ad2a5aa698a56d9387b78 /usr.sbin/sysinstall/tcpip.c
parent492e9838b2366b7c8f6fc4233dbc72db6def40d7 (diff)
downloadFreeBSD-src-c1afe7bbe25d479fb86ffe597401929339c59395.zip
FreeBSD-src-c1afe7bbe25d479fb86ffe597401929339c59395.tar.gz
Erm, correct mighty braino in previous "don't annoy me" change.
Diffstat (limited to 'usr.sbin/sysinstall/tcpip.c')
-rw-r--r--usr.sbin/sysinstall/tcpip.c17
1 files changed, 10 insertions, 7 deletions
diff --git a/usr.sbin/sysinstall/tcpip.c b/usr.sbin/sysinstall/tcpip.c
index 06d908b..8ccd6e8 100644
--- a/usr.sbin/sysinstall/tcpip.c
+++ b/usr.sbin/sysinstall/tcpip.c
@@ -1,5 +1,5 @@
/*
- * $Id: tcpip.c,v 1.77 1999/05/06 11:05:19 jkh Exp $
+ * $Id: tcpip.c,v 1.78 1999/05/07 05:15:17 jkh Exp $
*
* Copyright (c) 1995
* Gary J Palmer. All rights reserved.
@@ -264,23 +264,26 @@ reenter:
cancelbutton = okbutton = 0;
while (layoutDialogLoop(ds_win, layout, &obj, &n, max, &cancelbutton, &cancel)) {
/* Prevent this from being irritating if user really means NO */
- if (!filled) {
- filled = 1;
+ if (filled < 3) {
/* Insert a default value for the netmask, 0xffffff00 is
- the most appropriate one (entire class C, or subnetted
- class A/B network). */
+ * the most appropriate one (entire class C, or subnetted
+ * class A/B network).
+ */
if (netmask[0] == '\0') {
strcpy(netmask, "255.255.255.0");
RefreshStringObj(layout[LAYOUT_NETMASK].obj);
+ ++filled;
}
if (!index(hostname, '.') && domainname[0]) {
strcat(hostname, ".");
strcat(hostname, domainname);
RefreshStringObj(layout[LAYOUT_HOSTNAME].obj);
+ ++filled;
}
else if (((tmp = index(hostname, '.')) != NULL) && !domainname[0]) {
- SAFE_STRCPY(domainname, tmp + 1);
- RefreshStringObj(layout[LAYOUT_DOMAINNAME].obj);
+ SAFE_STRCPY(domainname, tmp + 1);
+ RefreshStringObj(layout[LAYOUT_DOMAINNAME].obj);
+ ++filled;
}
}
}
OpenPOWER on IntegriCloud