Date: Fri, 15 May 2009 00:18:31 +0000 (UTC) From: Colin Percival <cperciva@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r192130 - head/usr.sbin/sysinstall Message-ID: <200905150018.n4F0IVwb006628@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: cperciva Date: Fri May 15 00:18:31 2009 New Revision: 192130 URL: http://svn.freebsd.org/changeset/base/192130 Log: Allow a comma-separated list of network interfaces to be specified via the netDev option in install.cfg. Submitted by: randi MFC after: 1 week Modified: head/usr.sbin/sysinstall/tcpip.c Modified: head/usr.sbin/sysinstall/tcpip.c ============================================================================== --- head/usr.sbin/sysinstall/tcpip.c Thu May 14 23:09:33 2009 (r192129) +++ head/usr.sbin/sysinstall/tcpip.c Fri May 15 00:18:31 2009 (r192130) @@ -642,11 +642,26 @@ tcpDeviceSelect(void) { DMenu *menu; Device **devs, *rval; + char *dev, *network_dev; int cnt; + rval = NULL; + + if (variable_get(VAR_NONINTERACTIVE) && variable_get(VAR_NETWORK_DEVICE)) { + network_dev = variable_get(VAR_NETWORK_DEVICE); + + while ((dev = strsep(&network_dev, ",")) != NULL) { + devs = deviceFind(dev, DEVICE_TYPE_NETWORK); + cnt = deviceCount(devs); + if (cnt) { + if (DITEM_STATUS(tcpOpenDialog(devs[0]) == DITEM_SUCCESS)) + return(devs[0]); + } + } + } + devs = deviceFind(variable_get(VAR_NETWORK_DEVICE), DEVICE_TYPE_NETWORK); cnt = deviceCount(devs); - rval = NULL; if (!cnt) { msgConfirm("No network devices available!"); @@ -660,14 +675,6 @@ tcpDeviceSelect(void) if (DITEM_STATUS(tcpOpenDialog(devs[0]) == DITEM_SUCCESS)) rval = devs[0]; } - else if (variable_get(VAR_NONINTERACTIVE) && variable_get(VAR_NETWORK_DEVICE)) { - devs = deviceFind(variable_get(VAR_NETWORK_DEVICE), DEVICE_TYPE_NETWORK); - cnt = deviceCount(devs); - if (cnt) { - if (DITEM_STATUS(tcpOpenDialog(devs[0]) == DITEM_SUCCESS)) - rval = devs[0]; - } - } else { int status;
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200905150018.n4F0IVwb006628>