logical bug fix
This commit is contained in:
+2
-2
@@ -188,7 +188,7 @@ cidr_to_ips() {
|
||||
|
||||
# read
|
||||
[[ ! $mask == 24 ]] && [[ $HOST_SCAN == true ]] && { for ((c=0; c<116; c++)); do echo -n "-"; done; echo; }
|
||||
[[ ! $mask == 24 ]] && { [[ ${live_count["total"]} == 0 ]] && { for i in {1..4}; do UP='\033[1A'; printf "$UP"; done; cg_color bby "Either dead hosts in this subnet or ping is disabled :("; exit; } || { [[ $HOST_SCAN == true ]] && exit || { ips=($(sort -t. -n -k1,1 -k2,2 -k3,3 -k4,4 /tmp/ips)); return; }; }; }
|
||||
[[ ! $mask == 24 ]] && { [[ ${live_count["total"]} == 0 ]] && { [[ $HOST_SCAN == true ]] && { for i in {1..4}; do UP='\033[1A'; printf "$UP"; done; }; cg_color bby "Either dead hosts in this subnet or ping is disabled :("; exit; } || { [[ $HOST_SCAN == true ]] && exit || { ips=($(sort -t. -n -k1,1 -k2,2 -k3,3 -k4,4 /tmp/ips)); return; }; }; }
|
||||
[[ -f /tmp/ips ]] && ips=($(sort -t. -n -k +4 /tmp/ips)) || { cg_color bby "Either dead hosts in this subnet or ping is disabled :("; exit; }
|
||||
[[ $HOST_SCAN == true ]] && { out=${ips[*]}; l="\n"; echo -n "Number of live hosts: "; cg_color bbb ${#ips[@]}; echo -e "\e[1;92m${out//${IFS:0:1}/$l}\e[0m"; exit; } || return
|
||||
}
|
||||
@@ -275,4 +275,4 @@ elif [[ $cidr ]]; then
|
||||
[[ ($RUN_NMAP == true) && -f /tmp/tcp_ports ]] && echo
|
||||
cl
|
||||
done
|
||||
fi
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user