Modified if condition to work with busybox.

This commit is contained in:
Ronald Farrer 2020-04-14 21:57:54 -07:00
parent 313684fe3e
commit 9bba81ff5b

View file

@ -1,7 +1,7 @@
#!/bin/sh #!/bin/sh
# Version # Version
version=0.06 version=0.07
# A simple script that checks for connectivity (including working DNS resolution) # A simple script that checks for connectivity (including working DNS resolution)
# If no connectivity, reset tethering # If no connectivity, reset tethering
@ -26,7 +26,7 @@ while true; do
lsusb | grep $TETHERDEV > /dev/null lsusb | grep $TETHERDEV > /dev/null
# make sure there is a device connected before continuing # make sure there is a device connected before continuing
if (( $? )); then if [ $? == 1 ]; then
echo "Tethering device not found! Sleeping 5s..." echo "Tethering device not found! Sleeping 5s..."
sleep 5s sleep 5s
else else