chore: avoid ${var:-]} syntax, badly confusing vim's syntax highlighter

This commit is contained in:
Stéphane Lesimple 2019-11-23 16:02:00 +01:00
parent 6abe1bc62b
commit d519cc42c7
1 changed files with 2 additions and 1 deletions

View File

@ -1017,7 +1017,8 @@ pvulnstatus()
OK) is_vuln="false";;
*) echo "$0: error: unknown status '$2' passed to pvulnstatus()" >&2; exit 255;;
esac
json_output="${json_output:-[}{\"NAME\":\"$aka\",\"CVE\":\"$1\",\"VULNERABLE\":$is_vuln,\"INFOS\":\"$3\"},"
[ -z "$json_output" ] && json_output='['
json_output="${json_output}{\"NAME\":\"$aka\",\"CVE\":\"$1\",\"VULNERABLE\":$is_vuln,\"INFOS\":\"$3\"},"
;;
nrpe) [ "$2" = VULN ] && nrpe_vuln="$nrpe_vuln $1";;