diff options
author | Martin Cracauer <cracauer@FreeBSD.org> | 2000-02-15 08:00:11 +0000 |
---|---|---|
committer | Martin Cracauer <cracauer@FreeBSD.org> | 2000-02-15 08:00:11 +0000 |
commit | c11e75cfcf597bc93196026819fb9624689b439d (patch) | |
tree | a945adcbe639d042025bd045b86ca5d165a87e86 /bin | |
parent | 01ce53ab1ce93766f94a716224c97d9c80648917 (diff) | |
download | src-c11e75cfcf597bc93196026819fb9624689b439d.tar.gz src-c11e75cfcf597bc93196026819fb9624689b439d.zip |
Fix ${#varname} (getting length of string) when in double-quotes.
Approved-by: jkh
PR: bin/12137
Submitted by: "Danny J. Zerkel" <dzerkel@columbus.rr.com>
Notes
Notes:
svn path=/head/; revision=57225
Diffstat (limited to 'bin')
-rw-r--r-- | bin/sh/parser.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/bin/sh/parser.c b/bin/sh/parser.c index 3b93bd9b987d..2aa2665e0159 100644 --- a/bin/sh/parser.c +++ b/bin/sh/parser.c @@ -1248,7 +1248,7 @@ badsub: synerror("Bad substitution"); } else { pungetc(); } - if (dblquote || arinest) + if (subtype != VSLENGTH && (dblquote || arinest)) flags |= VSQUOTE; *(stackblock() + typeloc) = subtype | flags; if (subtype != VSNORMAL) |