Module Name:    src
Committed By:   jmmv
Date:           Mon Feb 25 18:49:51 UTC 2013

Modified Files:
        src/external/bsd/kyua-atf-compat/dist: atf-run.sh

Log Message:
Cherry-pick upstream change d0daf9983f5a0e635f1127dbc827aa114daa90d8:

Fix broken variable parsing with NetBSD's /bin/sh

Quote the expansion of a $() command that was not properly surrounded
by quotes so that this runs properly with NetBSD's /bin/sh.


To generate a diff of this commit:
cvs rdiff -u -r1.1.1.1 -r1.2 src/external/bsd/kyua-atf-compat/dist/atf-run.sh

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/external/bsd/kyua-atf-compat/dist/atf-run.sh
diff -u src/external/bsd/kyua-atf-compat/dist/atf-run.sh:1.1.1.1 src/external/bsd/kyua-atf-compat/dist/atf-run.sh:1.2
--- src/external/bsd/kyua-atf-compat/dist/atf-run.sh:1.1.1.1	Mon Feb 25 00:17:26 2013
+++ src/external/bsd/kyua-atf-compat/dist/atf-run.sh	Mon Feb 25 18:49:51 2013
@@ -66,11 +66,11 @@ load_configs() {
         local ws='[ \t]*'
         local name='[a-zA-Z][-_a-zA-Z0-9]*'
         local repl="--variable='${prefix}\\1=\\2'"
-        local vars=$(grep "^${ws}${name}${ws}=" "${file}" | \
+        local vars="$(grep "^${ws}${name}${ws}=" "${file}" | \
             sed -e 's,#(.*)$,,;s,unprivileged-user,unprivileged_user,g' \
             -e "s,^${ws}\(${name}\)${ws}=${ws}'\([^']*\)'${ws}$,${repl}," \
             -e "s,^${ws}\(${name}\)${ws}=${ws}\"\([^\"]*\)\"${ws}$,${repl}," \
-            -e "s,^${ws}\(${name}\)${ws}=${ws}\(.*\)$,${repl},")
+            -e "s,^${ws}\(${name}\)${ws}=${ws}\(.*\)$,${repl},")"
 
         lib_info "Extracted arguments: ${vars}"
         all_vars="${all_vars} ${vars}"

Reply via email to