]> git.ipfire.org Git - thirdparty/bash.git/blame - tests/new-exp6.sub
Bash-4.2 patch 7
[thirdparty/bash.git] / tests / new-exp6.sub
CommitLineData
0628567a
JA
1# quoted null problems in versions of bash prior to 3.2
2
3str='12'
4snul=$'\177'
5
6recho "${str:2}"
7recho "+${str:2}"
8recho "+${snul:0:1}"
9recho "+""${str:2}"
10
11recho "${str/?/$snul}"
12recho ${str/?/$snul}
13
14recho "${snul/x/y}"
15recho ${snul/x/y}
16
17recho "${snul/$snul/}"
18recho "${str/$str/}"
19
20recho "${snul##$snul}"
21recho "${str##$str}"
22recho "${str##$nul}"
3185942a
JA
23
24A=""
25B="${A:0}"
26
27recho "$B"
28recho "${A:0}"
29recho "/tmp/test/TEST${A:0}"