summaryrefslogtreecommitdiff
path: root/shell/hush_test
diff options
context:
space:
mode:
authorDenis Vlasenko2008-06-10 22:39:37 +0000
committerDenis Vlasenko2008-06-10 22:39:37 +0000
commit87f40bac149dcaf1025abd745decafb3a8ac4e0c (patch)
tree2ba28b5e62f88070cd6bfbda7486ab2125954bb3 /shell/hush_test
parent43360e51781942730f91bb19821e3f8f1087e4fa (diff)
downloadbusybox-87f40bac149dcaf1025abd745decafb3a8ac4e0c.zip
busybox-87f40bac149dcaf1025abd745decafb3a8ac4e0c.tar.gz
hush: more backtick and quoting fixes...
Diffstat (limited to 'shell/hush_test')
-rw-r--r--shell/hush_test/hush-psubst/tick3.right6
-rwxr-xr-xshell/hush_test/hush-psubst/tick3.tests11
2 files changed, 17 insertions, 0 deletions
diff --git a/shell/hush_test/hush-psubst/tick3.right b/shell/hush_test/hush-psubst/tick3.right
new file mode 100644
index 0000000..dc84e92
--- /dev/null
+++ b/shell/hush_test/hush-psubst/tick3.right
@@ -0,0 +1,6 @@
+\TESTZZBEST
+$TEST
+Q
+a\bc
+a"c
+done:0
diff --git a/shell/hush_test/hush-psubst/tick3.tests b/shell/hush_test/hush-psubst/tick3.tests
new file mode 100755
index 0000000..97b45e4
--- /dev/null
+++ b/shell/hush_test/hush-psubst/tick3.tests
@@ -0,0 +1,11 @@
+#!/bin/sh
+TEST=Q
+# \` is special
+echo `echo '\'TEST\`echo ZZ\`BEST`
+# \$ and \\ are special
+echo `echo \\$TEST`
+echo `echo \$TEST`
+echo a`echo \\\\b`c
+# \" etc are NOT special (passed verbatim WITH \)!
+echo a`echo \"`c
+echo done:$?