]> CyberLeo.Net >> Repos - FreeBSD/stable/10.git/blob - tools/regression/bin/sh/expansion/trim4.0
Copy head (r256279) to stable/10 as part of the 10.0-RELEASE cycle.
[FreeBSD/stable/10.git] / tools / regression / bin / sh / expansion / trim4.0
1 # $FreeBSD$
2
3 v1=/homes/SOME_USER
4 v2=
5 v3=C123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
6
7 # Trigger bug in VSTRIMRIGHT processing STADJUST() call in expand.c:subevalvar()
8 while [ ${#v2} -lt 2000 ]; do
9         v4="${v2} ${v1%/*} $v3"
10         if [ ${#v4} -ne $((${#v2} + ${#v3} + 8)) ]; then
11                 echo bad: ${#v4} -ne $((${#v2} + ${#v3} + 8))
12         fi
13         v2=x$v2
14         v3=y$v3
15 done