made STOP mode exit successfully; added support for restore option when specifying a filename on the command line

This commit is contained in:
Costa Tsaousis (ktsaou) 2015-03-23 17:19:49 +02:00
parent 67d402787a
commit d614fd7558

@ -10038,6 +10038,10 @@ case "${arg}" in
done
fi
success # "Clearing firewall"
# Remove the saved firewall, so that the trap will not restore it.
${RM_CMD} -f "${FIREHOL_SAVED}" "${FIREHOL_SAVED6}" >/dev/null 2>&1
# signal the trap to exit with success
FIREHOL_ACTIVATED_SUCCESSFULLY=1
exit 0
;;
@ -10392,10 +10396,14 @@ case "${arg}" in
shift
;;
--)
FIREHOL_TRY=1
restore|condrestart)
FIREHOL_RESTORE_INSTEAD_OF_START=1
FIREHOL_TRY=0
shift
;;
--) ;;
*)
echo >&2 "Cannot accept command line argument '${1}' here."
exit 1