diff options
author | jkh <jkh@FreeBSD.org> | 1999-05-07 11:45:26 +0000 |
---|---|---|
committer | jkh <jkh@FreeBSD.org> | 1999-05-07 11:45:26 +0000 |
commit | c1afe7bbe25d479fb86ffe597401929339c59395 (patch) | |
tree | a6d3e2fef42f07af333ad2a5aa698a56d9387b78 | |
parent | 492e9838b2366b7c8f6fc4233dbc72db6def40d7 (diff) | |
download | FreeBSD-src-c1afe7bbe25d479fb86ffe597401929339c59395.zip FreeBSD-src-c1afe7bbe25d479fb86ffe597401929339c59395.tar.gz |
Erm, correct mighty braino in previous "don't annoy me" change.
-rw-r--r-- | release/sysinstall/tcpip.c | 17 | ||||
-rw-r--r-- | usr.sbin/sysinstall/tcpip.c | 17 |
2 files changed, 20 insertions, 14 deletions
diff --git a/release/sysinstall/tcpip.c b/release/sysinstall/tcpip.c index 06d908b..8ccd6e8 100644 --- a/release/sysinstall/tcpip.c +++ b/release/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; } } } 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; } } } |