More all-caps variable elimination

Signed-off-by: Tom Eastep <teastep@shorewall.net>
This commit is contained in:
Tom Eastep 2010-02-26 17:05:35 -08:00
parent 061d850c16
commit 643d4831ab
2 changed files with 7 additions and 13 deletions

View File

@ -1068,12 +1068,6 @@ separate_list() {
# There's been whining about us not catching embedded white space in # There's been whining about us not catching embedded white space in
# comma-separated lists. This is an attempt to snag some of the cases. # comma-separated lists. This is an attempt to snag some of the cases.
# #
# The 'TERMINATOR' function will be set by the 'firewall' script to
# either 'startup_error' or 'fatal_error' depending on the command and
# command phase
#
[ -n "$TERMINATOR" ] && \
$TERMINATOR "Invalid comma-separated list \"$@\""
echo "WARNING -- invalid comma-separated list \"$@\"" >&2 echo "WARNING -- invalid comma-separated list \"$@\"" >&2
;; ;;
*\[*\]*) *\[*\]*)

View File

@ -362,7 +362,7 @@ compiler() {
[ -n "$SHOREWALL_DIR" ] && options="$options --directory=$SHOREWALL_DIR" [ -n "$SHOREWALL_DIR" ] && options="$options --directory=$SHOREWALL_DIR"
[ -n "$TIMESTAMP" ] && options="$options --timestamp" [ -n "$TIMESTAMP" ] && options="$options --timestamp"
[ -n "$g_test" ] && options="$options --test" [ -n "$g_test" ] && options="$options --test"
[ -n "$PREVIEW" ] && options="$options --preview" [ -n "$g_preview" ] && options="$options --preview"
[ "$g_debugging" = trace ] && options="$options --debug" [ "$g_debugging" = trace ] && options="$options --debug"
[ -n "$g_refreshchains" ] && options="$options --refresh=$g_refreshchains" [ -n "$g_refreshchains" ] && options="$options --refresh=$g_refreshchains"
# #
@ -642,7 +642,7 @@ check_command() {
option=${option#d} option=${option#d}
;; ;;
r*) r*)
PREVIEW=Yes; g_preview=Yes;
option=${option#r} option=${option#r}
;; ;;
*) *)
@ -1160,7 +1160,7 @@ reload_command() # $* = original arguments less the command.
local root local root
root=root root=root
LITEDIR=/var/lib/shorewall-lite litedir=/var/lib/shorewall-lite
while [ $finished -eq 0 -a $# -gt 0 ]; do while [ $finished -eq 0 -a $# -gt 0 ]; do
option=$1 option=$1
@ -1215,9 +1215,9 @@ reload_command() # $* = original arguments less the command.
;; ;;
esac esac
litedir=$(rsh_command /sbin/shorewall-lite show config 2> /dev/null | grep ^LITEDIR | sed 's/LITEDIR is //') litedir=$(rsh_command /sbin/shorewall-lite show config 2> /dev/null | grep ^litedir | sed 's/litedir is //')
[ -n "$litedir" ] && LITEDIR=$litedir [ -n "$litedir" ] && litedir=$litedir
if [ -z "$getcaps" ]; then if [ -z "$getcaps" ]; then
SHOREWALL_DIR=$(resolve_file $directory) SHOREWALL_DIR=$(resolve_file $directory)
@ -1245,8 +1245,8 @@ reload_command() # $* = original arguments less the command.
[ -n "$TIMESTAMP" ] && timestamp='-t' || timestamp= [ -n "$TIMESTAMP" ] && timestamp='-t' || timestamp=
if shorewall $g_debugging $verbose $timestamp compile -e $directory $directory/firewall && \ if shorewall $g_debugging $verbose $timestamp compile -e $directory $directory/firewall && \
progress_message3 "Copying $file and ${file}.conf to ${system}:${LITEDIR}..." && \ progress_message3 "Copying $file and ${file}.conf to ${system}:${litedir}..." && \
rcp_command "$directory/firewall $directory/firewall.conf" ${LITEDIR} rcp_command "$directory/firewall $directory/firewall.conf" ${litedir}
then then
save=$(find_file save); save=$(find_file save);