do not report errors on first run

This commit is contained in:
Daniel Steglich 2015-01-05 16:20:28 +00:00
parent c0f4b8205e
commit cb52d7fcf0

View File

@ -90,8 +90,8 @@ doWriteCFG()
#reset the last updated IP
echo "0.0.0.0" > $IPFILE
#reset last update
rm $STATUSFILE
#reset last update (if there is one)
rm $STATUSFILE 2> /dev/null
#find the interface (always the default gateway interface)
DEFAULT=`ip route |grep default |awk '{print $5}'`
@ -128,7 +128,7 @@ doWriteCFG()
doGetWANIP()
{
if [ $IPURL ];then
if [ ! -z $IPURL ];then
OUTFILE=`mktemp`
wget -4 -o /dev/null -O $OUTFILE $IPURL
WANIP=`cat $OUTFILE`