From ce9ad817170f085af9ed24e827e6cd33306e1024 Mon Sep 17 00:00:00 2001 From: Ing Date: Sat, 9 Mar 2024 16:48:47 +0800 Subject: [PATCH] fix typo --- files/initrd/opt/rr/include/functions.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/files/initrd/opt/rr/include/functions.sh b/files/initrd/opt/rr/include/functions.sh index b6be09be..7dc5106b 100755 --- a/files/initrd/opt/rr/include/functions.sh +++ b/files/initrd/opt/rr/include/functions.sh @@ -205,9 +205,9 @@ function _get_fastest() { done fastest="$(echo -e "${speedlist}" | tr -s '\n' | sort -k2n | head -1)" URL="$(echo "${fastest}" | awk '{print $1}')" - SPD="$(echo "${fastest}" | awk '{print $2}')" + SPD="$(echo "${fastest}" | awk '{print $2}')" # It is a float type echo "${URL}" - [ ${SPD:-999} -ge 999 ] && return 1 || return 0 + [ $(printf "%.0f" ${SPD:-999}) -ge 999 ] && return 1 || return 0 } ###############################################################################