dash.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Harald van Dijk <harald@gigawatt.nl>
To: Ron Yorston <rmy@frippery.org>,
	dash@vger.kernel.org, dash@mattwhitlock.name
Subject: Re: Bug in Dash's unquoting of backslashes within backquoted strings
Date: Thu, 21 May 2020 23:02:02 +0100	[thread overview]
Message-ID: <e8735922-37c2-0250-1956-079ea761f1fd@gigawatt.nl> (raw)
In-Reply-To: <5ec6f4d5.8pMzL3JNioCKa/Fi%rmy@frippery.org>

On 21/05/2020 22:38, Ron Yorston wrote:
> Matt Whitlock wrote:
>> A minimal example:
>>
>> : `: "\\\\
>> \\$(bug)"`
> 
>> However, when it appears inside a backquoted subcommand (with the
>> backslash characters being appropriately escaped), such as given at the top
>> of this report, then Dash processes it incorrectly:
>>
>> /bin/sh: 1: bug: not found
> 
> This seems to have been introduced by commit 6bbc71d (parser: use
> pgetc_eatbnl() in more places).  Reverting the following part of the
> commit makes the problem go away:

Yes, that commit (a patch I had submitted) was buggy and the part that 
you suggest reverting should be.

Cheers,
Harald van Dijk

      parent reply	other threads:[~2020-05-21 22:02 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-21 20:06 Bug in Dash's unquoting of backslashes within backquoted strings Matt Whitlock
2020-05-21 21:38 ` Ron Yorston
2020-05-21 21:57   ` Ron Yorston
2020-05-26 13:19     ` parser: Fix double-backslash nl in old-style command sub Herbert Xu
2020-05-21 22:02   ` Harald van Dijk [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=e8735922-37c2-0250-1956-079ea761f1fd@gigawatt.nl \
    --to=harald@gigawatt.nl \
    --cc=dash@mattwhitlock.name \
    --cc=dash@vger.kernel.org \
    --cc=rmy@frippery.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).