Signed-off-by: liudf0716 <liudf0716@gmail.com> [Fix indentation and trailing whitespace on Makefile and wifidogx.init] Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
7 lines
162 B
Bash
7 lines
162 B
Bash
#!/bin/sh
|
|
IP=$1
|
|
[ -x /usr/sbin/fping ] && {
|
|
fping -t 100 -c 1 $IP &> /dev/null && echo 1 || echo 0
|
|
} || {
|
|
ping -w 1 -c 1 $IP &> /dev/null && echo 1 || echo 0
|
|
}
|