[BUILTIN] Fix backslash handling in read(1)
commit6e1c8399e82c015f4e9d7d67e98d70541a3ef2d0
authorHerbert Xu <herbert@gondor.apana.org.au>
Fri, 11 Mar 2011 03:07:42 +0000 (11 11:07 +0800)
committerHerbert Xu <herbert@gondor.apana.org.au>
Fri, 11 Mar 2011 03:07:42 +0000 (11 11:07 +0800)
tree3f0360309fb374bca544a4527f4f63897a8a0418
parent8213431d222b56316e225a1f308b62a72fbb1faa
[BUILTIN] Fix backslash handling in read(1)

The new read(1) implementation incorrectly assumes that ifsbreakup
ignores characters escaped by CTLESC.  As such it fails to handle
backslashes except for escaping newlines.

This patch makes it use recordregion for every part that isn't
escaped by a backslash.

Reported-by: Jilles Tjoelker <jilles@stack.nl>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
ChangeLog
src/expand.c
src/miscbltin.c
src/mystring.c
src/mystring.h