All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Emma Tebibyte" <emma@tebibyte.media>
To: <dash@vger.kernel.org>
Subject: 
Date: Wed, 06 Dec 2023 21:40:42 -0700	[thread overview]
Message-ID: <CXHTPZE1MOGN.2SN9MFXJNGCB0@tebibyte.media> (raw)

Hi,

I found a bug in dash version 0.5.12 where when shifting more than ?#,
the shell exits before evaluating a logical OR operator.

To reproduce this issue:

	$ set -- 1
	$ shift 2 || printf 'meow\n'
	dash: 2: shift: can't shift that many
	$

This also occurs using if:

	$ set -- 1
	$ if shift 2; then
	> true
	> else
	> printf 'meow\n'
	> fi
	dash: 2: shift: can't shift that many
	$

Thanks,
Emma Tebibyte

             reply	other threads:[~2023-12-07  4:49 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-07  4:40 Emma Tebibyte [this message]
2023-12-07  5:00 ` Christoph Anton Mitterer
2023-12-07  5:29   ` Re: Lawrence Velázquez

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=CXHTPZE1MOGN.2SN9MFXJNGCB0@tebibyte.media \
    --to=emma@tebibyte.media \
    --cc=dash@vger.kernel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.