]> git.sthu.org Git - shutils.git/commitdiff
nsd-dynipwatch: make grep silent
authorStefan Huber <shuber2@gmx.at>
Sun, 28 Oct 2012 19:41:57 +0000 (20:41 +0100)
committerStefan Huber <shuber2@gmx.at>
Sun, 28 Oct 2012 19:41:57 +0000 (20:41 +0100)
nsd-dynipwatch

index fd064bbd1b931fd372a617fa9acb7be40f0b7f1f..a002f9576b3f8fa49408fe58af40025801617faf 100755 (executable)
@@ -52,7 +52,7 @@ function run()
                newip=`cat ${watchfile}`
                echo "`date '+%a %F %T'` :: ${oldip} => ${newip}."
 
-               if ! echo "${newip}" | egrep "^([0-9]+\\.)+[0-9]+$"  ; then
+               if ! echo "${newip}" | egrep -q "^([0-9]+\\.)+[0-9]+$"  ; then
                        echo "Wrong format of new IP address."
                        continue
                fi