Fixed a bug in integer entry.

This commit is contained in:
Fritz Elfert 1997-03-23 19:48:03 +00:00
parent dd7d85ae3f
commit 7b527a5b12
1 changed files with 3 additions and 3 deletions

View File

@ -333,14 +333,14 @@ function l_int () {
answer="`cat MCdialog.out`"
answer="${answer:-$3}"
if expr $answer : '0$\|-\?[1-9][0-9]*$' >/dev/null
if expr $answer : '0$\|[1-9][0-9]*$' >/dev/null
then
eval $2="$answer"
else
eval $2="$3"
echo -en "\007"
${DIALOG} --backtitle "$backtitle" \
--msgbox "You have made an invalid entry." 3 43
--msgbox "You have made an invalid entry." 5 43
fi
break
@ -1035,7 +1035,7 @@ followed by the <SPACE BAR>.
Press <?> for additional information about this option."
inputbox_instructions_int="\
Please enter a decimal value between 1 and 9999. \
Please enter a decimal value between 1 and 99999. \
Fractions will not be accepted. \
Use the <TAB> key to move from the input field to the buttons below it."