From f3e02dd6c2869165e2e4d86325f06be3aac81bb5 Mon Sep 17 00:00:00 2001 From: bbruns Date: Mon, 23 Aug 2010 21:44:40 +0000 Subject: [PATCH] More functions and help --- include/functions | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/include/functions b/include/functions index 8e82d89..0ceb80f 100644 --- a/include/functions +++ b/include/functions @@ -78,7 +78,7 @@ function reset_color { # could easily lock out the user from the network. Best way to be safe, is to # call iptables_policy_reset first then this function. function iptables_rules_flush { - IP_VERSION=$0 + IP_VERSION=$1 case $IP_VERSION in ipv6) VER_IPTABLES=$IP6TABLES ;; ipv4|*) VER_IPTABLES=$IPTABLES ;; @@ -98,8 +98,8 @@ function iptables_rules_flush { # iptables_policy_set (ipv6|ipv4) (ACCEPT|DROP) # Sets all policy rules to either ACCEPT or DROP for ipv4 or ipv6 function iptables_policy_reset { - IP_VERSION=$0 - SET_POLICY=${1=ACCEPT} + IP_VERSION=$1 + SET_POLICY=${2=ACCEPT} case $IP_VERSION in ipv6) VER_IPTABLES=$IP6TABLES ;; ipv4|*) VER_IPTABLES=$IPTABLES ;;