diff --git a/Shorewall-common/diff-3.4-shorewall b/Shorewall-common/diff-3.4-shorewall index 7c1f930cd..1ab7030f6 100644 --- a/Shorewall-common/diff-3.4-shorewall +++ b/Shorewall-common/diff-3.4-shorewall @@ -1,6 +1,6 @@ ---- /home/teastep/shorewall/branches/3.4/Shorewall/shorewall 2007-06-17 07:10:53.000000000 -0700 -+++ shorewall 2007-06-17 07:15:13.000000000 -0700 -@@ -1297,7 +1297,7 @@ +--- /home/teastep/shorewall/branches/3.4/Shorewall/shorewall 2007-06-18 10:56:27.000000000 -0700 ++++ shorewall 2007-06-18 10:54:54.000000000 -0700 +@@ -1305,7 +1305,7 @@ echo " stop" echo " status" echo " try [ -C {shell|perl} ] [ ]" @@ -9,7 +9,7 @@ echo " safe-start [ -C {shell|perl} ] [ ]" echo " safe-restart [ -C {shell|perl} ] [ ]" echo -@@ -1441,6 +1441,10 @@ +@@ -1449,6 +1449,10 @@ echo $version if [ -n "$all" ]; then diff --git a/Shorewall-common/shorewall b/Shorewall-common/shorewall index f3ecb7489..5e14f484c 100755 --- a/Shorewall-common/shorewall +++ b/Shorewall-common/shorewall @@ -274,19 +274,15 @@ compiler() { # We've now set SHOREWALL_DIR so recalculate CONFIG_PATH # ensure_config_path - # - # Run the appropriate params file - # - [ -d /usr/share/shorewall-perl ] && set -a; - - run_user_exit params - set +a + compiler= if [ -n "$SHOREWALL_COMPILER" ]; then - compiler="$SHOREWALL_COMPILER" + compiler="$SHOREWALL_COMPILER" #Compiler specified in /etc/shorewall/shorewall.conf or on the run-line elif [ -x $sc ]; then - compiler=shell + if [ ! -x $pc ]; then + compiler=shell + fi elif [ -x $pc ]; then compiler=perl else @@ -312,7 +308,13 @@ compiler() { # # And initiate the appropriate compiler # - [ -n "$SHOREWALL_COMPILER" ] && compiler="$SHOREWALL_COMPILER" + if [ -n "$SHOREWALL_COMPILER" ]; then + compiler="$SHOREWALL_COMPILER" + elif [ -x $sc ]; then + compiler=shell + else + compiler=perl + fi fi [ $command = exec ] || command= @@ -334,6 +336,12 @@ compiler() { [ -n "$SHOREWALL_DIR" ] && options="$options --directory $SHOREWALL_DIR "; [ -n "$TIMESTAMP" ] && options="$options --timestamp" ; [ -x $pc ] || startup_error "SHOREWALL_COMPILER=perl requires the shorewall-perl package which is not installed" + # + # Run the appropriate params file + # + set -a; + run_user_exit params + set +a $command perl $debugflags $pc $options $@ ;;