* [BUG] ignored substring parameter expansion after $@ ("$@""${v%/*}") command line)
@ 2017-09-26 3:39 G.raud
0 siblings, 0 replies; only message in thread
From: G.raud @ 2017-09-26 3:39 UTC (permalink / raw)
To: dash
To test that the param susbtitution in "$@""${v%*/}" is ignored (on a
command line or in an assignment):
$ dash -c 'v=1/2; w="$@""${v#*/}"; echo "$@""${v#*/}" "$w"'
Note that the quoting has to be around each variable, that the first has
to be $@ and that the bug occurs with %, %%, #, or ## substring
processing.
Adding a string in between the 2 required vars does not change the
behaviour:
$ dash -c 'v=1/2; echo "$@"s$u"s${v#*/}"'
except by adding a string, even empty, inside the quoting of $@:
$ dash -c 'v=1/2; echo "$a$@""${v#*/}"'
Regards
--
G.raud Meyer
graud@gmx.com
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2017-09-26 3:40 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-09-26 3:39 [BUG] ignored substring parameter expansion after $@ ("$@""${v%/*}") command line) G.raud
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).