NetBSD/bin/ksh
apb 3f6e3bc032 In foo="`echo \"hi\"`", the backslashes should be removed by the outer
double quotes, not seen by the inner backquotes.  Previously, ksh(1)
handled this correctly in non-posix mode but incorrectly in posix mode.

The previous comments in src/bin/ksh/lex.c quote parts of some version
of the POSIX specification.  The version of POSIX being quoted is not
identified, but the wording is very similar to that in SUSv3
<http://www.opengroup.org/onlinepubs/009695399/utilities/xcu_chap02.html>.

It seems clear that the words "having escape characters removed"
mean, in that context, that the backslash before the double quote in
"...`...\"...`..." is removed as part of the handling of the outer
double quotes, so that the backslash is not present when the inner
backquotes are handled.  The new code in this commit follows this
interpretation.  The previous code followed a different interpretation
which is now believed to be incorrect.

Discussed in tech-userlevel.  Closes PR 26493.
2008-10-27 19:52:28 +00:00
..
Makefile Pass SED=${TOOL_SED:Q} in the environment to scripts run during the build. 2008-10-25 22:23:55 +00:00
alloc.c use __RCSID() 2007-12-12 22:55:42 +00:00
c_ksh.c
c_sh.c
c_test.c
c_test.h
c_ulimit.c Avoid sign extention problems leading to: 2008-09-14 05:00:23 +00:00
conf-end.h
config.h
edit.c * Escape '?', '[', ']' like other meta characters. 2007-01-28 20:20:25 +00:00
edit.h
emacs-gen.sh In shell scripts run during the build, add a SED variable, defaulting 2008-10-25 22:18:15 +00:00
emacs.c
eval.c Applied patch by Arto Huusko from PR bin/24753 to append a slash to "." 2007-01-28 22:30:12 +00:00
exec.c
expand.h
expr.c
history.c
io.c
jobs.c
ksh.Man In foo="`echo \"hi\"`", the backslashes should be removed by the outer 2008-10-27 19:52:28 +00:00
ksh_dir.h
ksh_limval.h
ksh_stat.h
ksh_time.h
ksh_times.h
ksh_wait.h
lex.c In foo="`echo \"hi\"`", the backslashes should be removed by the outer 2008-10-27 19:52:28 +00:00
lex.h
mail.c
main.c PR/36546: Aleksey Cheusov: problems with 8-bit input in /bin/ksh, needs to 2007-06-24 18:00:49 +00:00
misc.c
mkman In shell scripts invoked during a build, and in crunchgen, use ${AWK} 2008-10-19 22:10:04 +00:00
path.c
proto.h
sh.h
shf.c
shf.h
sigact.c
sigact.h
siglist.in
siglist.sh In shell scripts run during the build, add a SED variable, defaulting 2008-10-25 22:18:15 +00:00
syn.c use c99 initializers 2006-10-16 00:07:32 +00:00
table.c
table.h
trap.c use c99 initializers 2006-10-16 00:07:32 +00:00
tree.c
tree.h
tty.c
tty.h
var.c
version.c
vi.c