mirror of
https://github.com/darkclip/netlist.git
synced 2026-11-14 23:03:46 +08:00
update
This commit is contained in:
1 parent
cf47dd3937
commit
27f44c8e72
1 file changed
+3
-2
+3
-2
@@ -6,8 +6,9 @@ get_rnd(){
|
||||
};
|
||||
|
||||
get_ping_loss(){
|
||||
loss_percent=$(ping -c 5 -q $1 | awk '/packet loss/{print $(NF-4)}');
|
||||
echo ${loss_percent%?};
|
||||
loss_percent=$(ping -c 5 -q $1 | awk '/packet loss/{print $((NF-4))}');
|
||||
loss=${loss_percent%?};
|
||||
echo ${loss%.*}
|
||||
return $?;
|
||||
};
|
||||
|
||||
|
||||
Reference in new issue
Block a user