Fix unbound literal in trueorfalse()
Change-Id: I4c465819c311604e97d24e081389ff531f8a42fa
This commit is contained in:
parent
b9a7d3b5e4
commit
a1b82cc1b5
@ -245,7 +245,7 @@ function trueorfalse {
|
||||
set +o xtrace
|
||||
local default=$1
|
||||
local literal=$2
|
||||
local testval=${!literal}
|
||||
local testval=${!literal:-}
|
||||
|
||||
[[ -z "$testval" ]] && { echo "$default"; return; }
|
||||
[[ "0 no No NO false False FALSE" =~ "$testval" ]] && { echo "False"; return; }
|
||||
|
Loading…
x
Reference in New Issue
Block a user