check_uptime: fix floating point error
This commit is contained in:
parent
5a34281bde
commit
e78294d7d9
|
@ -10,6 +10,8 @@ if uname | grep -q "BSD"; then
|
|||
total_uptime_seconds=$(($(date +%s) - boot_time_seconds))
|
||||
else
|
||||
total_uptime_seconds=$(cat /proc/uptime | awk '{print $1}')
|
||||
total_uptime_seconds=$(printf "%.0f" "${total_uptime_seconds}")
|
||||
#else
|
||||
# echo "UNKNOWN: Unsupported system"
|
||||
# exit 3
|
||||
fi
|
||||
|
|
Loading…
Reference in New Issue