Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F142528489
D35267.id106198.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
2 KB
Referenced Files
None
Subscribers
None
D35267.id106198.diff
View Options
Index: usr.sbin/bsdinstall/scripts/netconfig_ipv4
===================================================================
--- usr.sbin/bsdinstall/scripts/netconfig_ipv4
+++ usr.sbin/bsdinstall/scripts/netconfig_ipv4
@@ -36,28 +36,31 @@
############################################################ MAIN
+: ${BSDDIALOG_OK=0}
+: ${BSDDIALOG_CANCEL=1}
+
INTERFACE=$1
IFCONFIG_PREFIX="$2"
test -z "$IFCONFIG_PREFIX" || IFCONFIG_PREFIX="$2 "
case "${INTERFACE}" in
-"") dialog --backtitle 'FreeBSD Installer' --title 'Network Configuration' \
+"") bsddialog --backtitle 'FreeBSD Installer' --title 'Network Configuration' \
--msgbox 'No interface specified for IPv4 configuration.' 0 0
exit 1
;;
esac
-dialog --backtitle 'FreeBSD Installer' --title 'Network Configuration' --yesno 'Would you like to use DHCP to configure this interface?' 0 0
-if [ $? -eq $DIALOG_OK ]; then
+bsddialog --backtitle 'FreeBSD Installer' --title 'Network Configuration' --yesno 'Would you like to use DHCP to configure this interface?' 0 0
+if [ $? -eq $BSDDIALOG_OK ]; then
if [ ! -z $BSDINSTALL_CONFIGCURRENT ]; then
# XXX: get interface down otherwise after installation restart
# dhclient does not build a new resolv.conf (see PR262262).
ifconfig $INTERFACE down
ifconfig $INTERFACE up
- dialog --backtitle 'FreeBSD Installer' --infobox "Acquiring DHCP lease..." 0 0
+ bsddialog --backtitle 'FreeBSD Installer' --infobox "Acquiring DHCP lease..." 0 0
err=$( pkill -F /var/run/dhclient/dhclient.${INTERFACE}.pid; dhclient $INTERFACE 2>&1 )
if [ $? -ne 0 ]; then
f_dprintf "%s" "$err"
- dialog --backtitle 'FreeBSD Installer' --msgbox "DHCP lease acquisition failed." 0 0
+ bsddialog --backtitle 'FreeBSD Installer' --msgbox "DHCP lease acquisition failed." 0 0
exec $0 ${INTERFACE} "${IFCONFIG_PREFIX}"
fi
fi
@@ -70,12 +73,12 @@
ROUTER=`netstat -rn -f inet | awk '/default/ {printf("%s\n", $2);}'`
exec 3>&1
-IF_CONFIG=$(dialog --backtitle 'FreeBSD Installer' --title 'Network Configuration' --form 'Static Network Interface Configuration' 0 0 0 \
- 'IP Address' 1 0 "$IP_ADDRESS" 1 20 16 0 \
- 'Subnet Mask' 2 0 "$NETMASK" 2 20 16 0 \
- 'Default Router' 3 0 "$ROUTER" 3 20 16 0 \
+IF_CONFIG=$(bsddialog --backtitle 'FreeBSD Installer' --title 'Network Configuration' --form 'Static Network Interface Configuration' 0 0 0 \
+ 'IP Address' 1 1 "$IP_ADDRESS" 1 20 16 0 \
+ 'Subnet Mask' 2 1 "$NETMASK" 2 20 16 0 \
+ 'Default Router' 3 1 "$ROUTER" 3 20 16 0 \
2>&1 1>&3)
-if [ $? -eq $DIALOG_CANCEL ]; then exit 1; fi
+if [ $? -eq $BSDDIALOG_CANCEL ]; then exit 1; fi
exec 3>&-
echo $INTERFACE $IF_CONFIG |
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Jan 21, 4:00 PM (10 h, 29 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
27812590
Default Alt Text
D35267.id106198.diff (2 KB)
Attached To
Mode
D35267: bsdinstall netconfig_ipv4: replace dialog(1) with bsddialog(1)
Attached
Detach File
Event Timeline
Log In to Comment