X-Git-Url: http://git.squeep.com/?a=blobdiff_plain;f=xenophobe.sh;h=d3edecb8fe3bddf1a4724b987094f48d4e332183;hb=a9ed0b8be1b17ed3d6e4e83a18e38650a4dc29be;hp=91d250a3eb3e6748ecd5075e750ed39a5c3c998c;hpb=cfde4971df11b411615d4e133a372a6d51d7ad97;p=firewall-squeep diff --git a/xenophobe.sh b/xenophobe.sh index 91d250a..d3edecb 100755 --- a/xenophobe.sh +++ b/xenophobe.sh @@ -20,7 +20,7 @@ create_set "${set_name}" hash:net create_set "${set_name}6" hash:net family inet6 # create or re-init chains -if ! $IPTABLES -L "${chain}" >/dev/null +if ! $IPTABLES -L "${chain}" >/dev/null 2>&1 then echo "initializing chain '${chain}'" $IPTABLES -N "${chain}" || $IPTABLES -F "${chain}" @@ -29,7 +29,7 @@ then $IPTABLES -v -L "${chain}" fi -if ! $IP6TABLES -L "${chain}" >/dev/null +if ! $IP6TABLES -L "${chain}" >/dev/null 2>&1 then echo "initializing chain '${chain}' ipv6" $IP6TABLES -N "${chain}" || $IP6TABLES -F "${chain}"