From 269b9eff84316b9390bf428dc523d98e42091f0d Mon Sep 17 00:00:00 2001 From: Jake Guffey Date: Wed, 19 Sep 2012 17:07:56 -0400 Subject: [PATCH] Escape inner variable ret was being set and checked in generated code but the $ wasn't being escaped --- conf/type/__pf_apply/gencode-remote | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/conf/type/__pf_apply/gencode-remote b/conf/type/__pf_apply/gencode-remote index 9288d3e2..5a027984 100755 --- a/conf/type/__pf_apply/gencode-remote +++ b/conf/type/__pf_apply/gencode-remote @@ -47,12 +47,9 @@ elif [ -f "${rcvar}.new" ]; then # rcvar.new exists, we must need to apply it # Cleanup # This file shouldn't exist, but just in case rm -f "${rcvar}.old" - if [ "$ret" -ne "0" ]; then # failed to configure new ruleset + if [ "\$ret" -ne "0" ]; then # failed to configure new ruleset echo "Failed to configure the new ruleset on ${__target_host}!" >&2 fi -else # neither ${rcvar}.old nor ${rcvar}.new exist? error. - echo "Neither ${rcvar}.old nor ${rcvar}.new exist! Something is wrong." >&2 - exit 1 fi EOF