aboutgitcode
diff options
context:
space:
mode:
authorSevinj Aghayeva <sevinj.aghayeva@gmail.com>2022-04-17 13:27:20 -0400
committerStefano Brivio <sbrivio@redhat.com>2022-04-21 16:40:29 +0200
commit4447d4b29682a5aa4b09c47de9a1659b0f167d3b (patch)
tree0ce0699e5f987908fd6e79928c3937adb56ed442
parent2458f4064b63e251892bdad5a9c5d2e539def0c0 (diff)
downloadmbuto-4447d4b29682a5aa4b09c47de9a1659b0f167d3b.tar
mbuto-4447d4b29682a5aa4b09c47de9a1659b0f167d3b.tar.gz
mbuto-4447d4b29682a5aa4b09c47de9a1659b0f167d3b.tar.bz2
mbuto-4447d4b29682a5aa4b09c47de9a1659b0f167d3b.tar.lz
mbuto-4447d4b29682a5aa4b09c47de9a1659b0f167d3b.tar.xz
mbuto-4447d4b29682a5aa4b09c47de9a1659b0f167d3b.tar.zst
mbuto-4447d4b29682a5aa4b09c47de9a1659b0f167d3b.zip
mbuto: quote variables when calling eval
We need to pass suboptions multiple arguments as a single string, as in SUBOPT_collection="net proc" Without these quotes the result of eval becomes SUBOPT_collection=net proc which assings only the value "net" to SUBOPT_collection. Signed-off-by: Sevinj Aghayeva <sevinj.aghayeva@gmail.com>
-rwxr-xr-xmbuto2
1 files changed, 1 insertions, 1 deletions
diff --git a/mbuto b/mbuto
index 44b9a56..f9ee6c5 100755
--- a/mbuto
+++ b/mbuto
@@ -497,7 +497,7 @@ subopts_get_one() {
[ "${__profile}" != "${PROFILE}" ] && return 1
[ "${__passed}" != "${__short}" ] && return 1
- eval $(echo SUBOPT_${__name}="${__value}")
+ eval $(echo SUBOPT_${__name}=\"${__value}\")
}
# subopts_get() - Set sub-option values, validating against SUBOPTS