]> git.ipfire.org Git - thirdparty/iptables.git/commitdiff
iptables-apply: Quote strings passed to echo
authorPhil Sutter <phil@nwl.cc>
Wed, 19 Sep 2018 13:16:57 +0000 (15:16 +0200)
committerFlorian Westphal <fw@strlen.de>
Mon, 24 Sep 2018 09:24:11 +0000 (11:24 +0200)
Not a real problem here, but covscan got confused by one string
containing 'then' keyword.

Signed-off-by: Phil Sutter <phil@nwl.cc>
Signed-off-by: Florian Westphal <fw@strlen.de>
iptables/iptables-apply

index 86b8d5a2ffcc9f839479ce69125f23cad01013e2..c7b12d07e584bd949c8c076036fd8dccff75712c 100755 (executable)
@@ -143,7 +143,7 @@ if ! "$RESTORE" <"$FILE"; then
        echo "E: unknown error applying new iptables ruleset." >&2
        exit 5
 else
-       echo done.
+       echo "done."
 fi
 
 echo -n "Can you establish NEW connections to the machine? (y/N) "
@@ -152,7 +152,7 @@ read -n1 -t "${TIMEOUT:-15}" ret 2>&1 || :
 case "${ret:-}" in
        (y*|Y*)
                echo
-               echo ... then my job is done. See you next time.
+               echo "... then my job is done. See you next time."
                ;;
        (*)
                if [[ -z "${ret:-}" ]]; then
@@ -163,7 +163,7 @@ case "${ret:-}" in
                echo "Timeout. Something happened (or did not). Better play it safe..."
                echo -n "Reverting to old ruleset... "
                "$RESTORE" <"$TMPFILE";
-               echo done.
+               echo "done."
                exit 255
                ;;
 esac