too many arguments
This commit is contained in:
parent
c4d9e053ee
commit
ed19ae5c0d
@ -27,7 +27,7 @@ function g_calc {
|
||||
read -u ${g_fd_bc_out} g_calc_result
|
||||
|
||||
# check if there is a output
|
||||
if [ -z $g_calc_result ]
|
||||
if [ -z "$g_calc_result" ]
|
||||
then
|
||||
echo "${FUNCNAME} $@" 1>&2
|
||||
unset g_calc_result
|
||||
@ -48,7 +48,7 @@ function g_calc {
|
||||
[[ $g_calc_result == *"." ]] && g_calc_result=${g_calc_result%?}
|
||||
|
||||
# check output
|
||||
if ! g_num_valid_number $g_calc_result
|
||||
if ! g_num_valid_number "$g_calc_result"
|
||||
then
|
||||
echo "${FUNCNAME} $@" 1>&2
|
||||
unset g_calc_result
|
||||
|
Loading…
Reference in New Issue
Block a user