[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bash $'foo' quoting problem
From: |
Dr. Werner Fink |
Subject: |
bash $'foo' quoting problem |
Date: |
Mon, 13 Feb 2006 12:39:33 +0100 |
User-agent: |
Mutt/1.5.9i |
Hi,
the bash-3.1.5 has a problem with quoting which leads to
a different output of
echo $(set -- $'a b'; echo $#)
and
echo "$(set -- $'a b'; echo $#)"
The patch below fix this problem.
Werner
--------------------------------------------------------------------------------
*** parse.y
--- parse.y Tue Jan 10 11:36:59 2006
***************
*** 2842,2848 ****
ttrans = ansiexpand (nestret, 0, nestlen - 1, &ttranslen);
xfree (nestret);
! if ((rflags & P_DQUOTE) == 0)
{
nestret = sh_single_quote (ttrans);
free (ttrans);
--- 2842,2848 ----
ttrans = ansiexpand (nestret, 0, nestlen - 1, &ttranslen);
xfree (nestret);
! if (extended_quote || (rflags & P_DQUOTE) == 0)
{
nestret = sh_single_quote (ttrans);
free (ttrans);
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- bash $'foo' quoting problem,
Dr. Werner Fink <=