Re: Bash bug interpolating delete characters

2012-05-07 Thread John Kearney
Am 07.05.2012 22:46, schrieb Chet Ramey: > On 5/3/12 5:53 AM, Ruediger Kuhlmann wrote: >> Hi, >> >> please try the following bash script: >> >> a=x >> del="$(echo -e "\\x7f")" >> >> echo "$del${a#x}" | od -ta >> echo "$del ${a#x}" | od -ta >> echo " $del${a#x}" | od -ta >> >> Using bash 3.2, the ou

Re: Bash bug interpolating delete characters

2012-05-07 Thread Chet Ramey
On 5/3/12 5:53 AM, Ruediger Kuhlmann wrote: > Hi, > > please try the following bash script: > > a=x > del="$(echo -e "\\x7f")" > > echo "$del${a#x}" | od -ta > echo "$del ${a#x}" | od -ta > echo " $del${a#x}" | od -ta > > Using bash 3.2, the output is: > > 000 del nl > 002 > 000 d

Re: Fwd: Bash bug interpolating delete characters

2012-05-03 Thread John Kearney
Am 03.05.2012 19:41, schrieb John Kearney: > Am 03.05.2012 15:01, schrieb Greg Wooledge: >>> Yours, Rüdiger. >>> a=x >>> del="$(echo -e "\\x7f")" >>> >>> echo "$del${a#x}" | od -ta >>> echo "$del ${a#x}" | od -ta >>> echo " $del${a#x}" | od -ta >> Yup, confirmed that it breaks here, and only when t

Re: Fwd: Bash bug interpolating delete characters

2012-05-03 Thread John Kearney
Am 03.05.2012 15:01, schrieb Greg Wooledge: >> Yours, Rüdiger. >> a=x >> del="$(echo -e "\\x7f")" >> >> echo "$del${a#x}" | od -ta >> echo "$del ${a#x}" | od -ta >> echo " $del${a#x}" | od -ta > Yup, confirmed that it breaks here, and only when the # parameter expansion > is included. > > imadev:~$

Re: Fwd: Bash bug interpolating delete characters

2012-05-03 Thread Greg Wooledge
> Yours, Rüdiger. > a=x > del="$(echo -e "\\x7f")" > > echo "$del${a#x}" | od -ta > echo "$del ${a#x}" | od -ta > echo " $del${a#x}" | od -ta Yup, confirmed that it breaks here, and only when the # parameter expansion is included. imadev:~$ del=$'\x7f' a=x b= imadev:~$ echo " $del$b" | od -ta 0

Fwd: Bash bug interpolating delete characters

2012-05-03 Thread Chet Ramey
--- Begin Message --- Hi, please try the following bash script: a=x del="$(echo -e "\\x7f")" echo "$del${a#x}" | od -ta echo "$del ${a#x}" | od -ta echo " $del${a#x}" | od -ta Using bash 3.2, the output is: 000 del nl 002 000 del sp nl 003 000 sp del nl 003 howeve