routing.subr (ab2043b81eaba0d7d7769b4a58b2b6d17bc464a3) routing.subr (89498fdf4174b08bb67d684d14886539aff698b4)
1if [ ! "$_NETWORKING_ROUTING_SUBR" ]; then _NETWORKING_ROUTING_SUBR=1
2#
3# Copyright (c) 2006-2012 Devin Teske
4# All Rights Reserved.
5#
6# Redistribution and use in source and binary forms, with or without
7# modification, are permitted provided that the following conditions
8# are met:

--- 96 unchanged lines hidden (view full) ---

105 "$msg" \
106 "$defaultrouter" \
107 "$hline" )"
108
109 #
110 # Loop until the user provides taint-free input.
111 #
112 while :; do
1if [ ! "$_NETWORKING_ROUTING_SUBR" ]; then _NETWORKING_ROUTING_SUBR=1
2#
3# Copyright (c) 2006-2012 Devin Teske
4# All Rights Reserved.
5#
6# Redistribution and use in source and binary forms, with or without
7# modification, are permitted provided that the following conditions
8# are met:

--- 96 unchanged lines hidden (view full) ---

105 "$msg" \
106 "$defaultrouter" \
107 "$hline" )"
108
109 #
110 # Loop until the user provides taint-free input.
111 #
112 while :; do
113 eval $DIALOG \
113 local dialog_inputbox
114 dialog_inputbox=$( eval $DIALOG \
114 --title \"\$DIALOG_TITLE\" \
115 --backtitle \"\$DIALOG_BACKTITLE\" \
116 --hline \"\$hline\" \
117 --ok-label \"\$msg_ok\" \
118 --cancel-label \"\$msg_cancel\" \
119 --inputbox \"\$msg\" $size \
120 \"\$defaultrouter\" \
115 --title \"\$DIALOG_TITLE\" \
116 --backtitle \"\$DIALOG_BACKTITLE\" \
117 --hline \"\$hline\" \
118 --ok-label \"\$msg_ok\" \
119 --cancel-label \"\$msg_cancel\" \
120 --inputbox \"\$msg\" $size \
121 \"\$defaultrouter\" \
121 2> "$DIALOG_TMPDIR/dialog.inputbox.$$"
122 2>&1 >&$DIALOG_TERMINAL_PASSTHRU_FD
123 )
122
123 local retval=$?
124
125 local retval=$?
126 setvar DIALOG_INPUTBOX_$$ "$dialog_inputbox"
124 defaultrouter=$( f_dialog_inputstr )
125
126 [ "$defaultrouter" ] || return $SUCCESS
127 [ $retval -eq $SUCCESS ] || return $retval
128
129 # Taint-check the user's input
130 f_dialog_validate_ipaddr "$defaultrouter" && break
131 done

--- 37 unchanged lines hidden ---
127 defaultrouter=$( f_dialog_inputstr )
128
129 [ "$defaultrouter" ] || return $SUCCESS
130 [ $retval -eq $SUCCESS ] || return $retval
131
132 # Taint-check the user's input
133 f_dialog_validate_ipaddr "$defaultrouter" && break
134 done

--- 37 unchanged lines hidden ---