summaryrefslogtreecommitdiffstats
path: root/usr.sbin/bsdconfig/share/media/ftp.subr
diff options
context:
space:
mode:
authordteske <dteske@FreeBSD.org>2013-10-09 08:12:26 +0000
committerdteske <dteske@FreeBSD.org>2013-10-09 08:12:26 +0000
commitee2fafc6a903bcdb2569fc1d6c3ffce0f14c3ebd (patch)
tree4b1792e416c982abbc7d554b2fb8ab80ba5afb91 /usr.sbin/bsdconfig/share/media/ftp.subr
parent255d648aec920f8660ba18ef659a9a08f5ee0198 (diff)
downloadFreeBSD-src-ee2fafc6a903bcdb2569fc1d6c3ffce0f14c3ebd.zip
FreeBSD-src-ee2fafc6a903bcdb2569fc1d6c3ffce0f14c3ebd.tar.gz
Introduce centralized [X]dialog(1) exit codes to `dialog.subr' and make-use
throughout the bsdconfig(8) code. While we're here, add an explicit argument to lvalue-seeking invocations of "return" that previously had no argument. Also, consolidate a single instance of double-newline and remove some comments that are no longer required (given increased readability with new exit codes). Approved by: re (glebius)
Diffstat (limited to 'usr.sbin/bsdconfig/share/media/ftp.subr')
-rw-r--r--usr.sbin/bsdconfig/share/media/ftp.subr6
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.sbin/bsdconfig/share/media/ftp.subr b/usr.sbin/bsdconfig/share/media/ftp.subr
index 5aad8ee..d7f33bb 100644
--- a/usr.sbin/bsdconfig/share/media/ftp.subr
+++ b/usr.sbin/bsdconfig/share/media/ftp.subr
@@ -213,7 +213,7 @@ f_dialog_menu_media_ftp()
$height $width $rows \
$menu_list \
2>&1 >&$DIALOG_TERMINAL_PASSTHRU_FD
- ) || return $FAILURE
+ ) || return $DIALOG_CANCEL
f_dialog_data_sanitize mtag
case "$mtag" in
@@ -224,7 +224,7 @@ f_dialog_menu_media_ftp()
setvar $VAR_FTP_PATH "ftp://$value"
esac
- return $SUCCESS
+ return $DIALOG_OK
}
# f_media_set_ftp
@@ -740,7 +740,7 @@ f_media_init_ftp()
else
f_yesno "$msg_cant_find_distribution" \
"$rel" "$ftp_host"
- if [ $? -eq $SUCCESS ]; then
+ if [ $? -eq $DIALOG_OK ]; then
unset $VAR_FTP_PATH
f_media_set_ftp && continue
fi
OpenPOWER on IntegriCloud