summaryrefslogtreecommitdiff
path: root/tools/ds-identify
diff options
context:
space:
mode:
authorScott Moser <smoser@brickies.net>2017-02-24 22:42:50 -0500
committerScott Moser <smoser@brickies.net>2017-02-24 22:46:32 -0500
commitcff1335be979fd1be5512d241ab861cfe70d82f0 (patch)
tree1e73dbc1cfd02214a0b65a0ea36559d85cc93df2 /tools/ds-identify
parent5551e8fc40ba37f0bd133f9478a8db8ce9f79dd7 (diff)
downloadvyos-cloud-init-cff1335be979fd1be5512d241ab861cfe70d82f0.tar.gz
vyos-cloud-init-cff1335be979fd1be5512d241ab861cfe70d82f0.zip
tools/ds-identify: use quotes in local declarations.
The following can have cause issue: FOO="bar ; wark" showit() { local b=$FOO echo $b } 4: local: ;: bad variable name The answer is just to use more quotes.
Diffstat (limited to 'tools/ds-identify')
-rwxr-xr-xtools/ds-identify4
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/ds-identify b/tools/ds-identify
index 9b14b92a..f2878745 100755
--- a/tools/ds-identify
+++ b/tools/ds-identify
@@ -601,7 +601,7 @@ dscheck_Ec2() {
fi
# product uuid and product serial start with case insensitive
- local uuid=${DI_DMI_PRODUCT_UUID} serial=${DI_DMI_PRODUCT_SERIAL}
+ local uuid="${DI_DMI_PRODUCT_UUID}" serial="${DI_DMI_PRODUCT_SERIAL}"
case "$uuid:$serial" in
[Ee][Cc]2*:[Ee][Cc]2)
# both start with ec2, now check for case insenstive equal
@@ -883,7 +883,7 @@ parse_policy() {
}
read_config() {
- local config=${PATH_DI_CONFIG}
+ local config="${PATH_DI_CONFIG}"
local _rc_dsname="" _rc_policy="" ret=""
if [ -f "$config" ]; then
_read_config < "$config"