Fix LOGFILE (again)

git-svn-id: https://shorewall.svn.sourceforge.net/svnroot/shorewall/trunk@6448 fbd18981-670d-0410-9b5c-8dc0c1a9a2bb
This commit is contained in:
teastep 2007-05-28 20:34:48 +00:00
parent 2e2f1e2977
commit 3572b6513a

View File

@ -152,6 +152,7 @@ get_config() {
# #
export CONFIG_PATH export CONFIG_PATH
if [ "$2" = Yes ]; then
[ -z "$LOGFILE" ] && LOGFILE=/var/log/messages [ -z "$LOGFILE" ] && LOGFILE=/var/log/messages
if [ -n "$(syslog_circular_buffer)" ]; then if [ -n "$(syslog_circular_buffer)" ]; then
@ -162,6 +163,7 @@ get_config() {
echo "LOGFILE ($LOGFILE) does not exist!" >&2 echo "LOGFILE ($LOGFILE) does not exist!" >&2
exit 2 exit 2
fi fi
fi
if [ -n "$IPTABLES" ]; then if [ -n "$IPTABLES" ]; then
if [ ! -x "$IPTABLES" ]; then if [ ! -x "$IPTABLES" ]; then
@ -196,10 +198,11 @@ get_config() {
export RESTOREFILE export RESTOREFILE
if [ "$2" = Yes ]; then
case $STARTUP_ENABLED in case $STARTUP_ENABLED in
No|no|NO) No|no|NO)
echo " WARNING: Shorewall startup is disabled. To enable startup, set STARTUP_ENABLED=Yes in ${CONFDIR}/shorewall.conf" >&2 echo " ERROR: Shorewall startup is disabled. To enable startup, set STARTUP_ENABLED=Yes in ${CONFDIR}/shorewall.conf" >&2
STARTUP_ENABLED= exit 2
;; ;;
Yes|yes|YES) Yes|yes|YES)
;; ;;
@ -210,6 +213,7 @@ get_config() {
fi fi
;; ;;
esac esac
fi
case ${TC_ENABLED:=Internal} in case ${TC_ENABLED:=Internal} in
No|NO|no) No|NO|no)
@ -1461,7 +1465,7 @@ COMMAND=$1
case "$COMMAND" in case "$COMMAND" in
start) start)
get_config get_config No Yes
shift shift
start_command $@ start_command $@
;; ;;
@ -1477,12 +1481,12 @@ case "$COMMAND" in
compile_command $@ compile_command $@
;; ;;
restart) restart)
get_config get_config No Yes
shift shift
restart_command $@ restart_command $@
;; ;;
refresh) refresh)
get_config get_config No Yes
shift shift
refresh_command $@ refresh_command $@
;; ;;