[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Shell exits after process substitution when using DEBUG trap with ex
From: |
Jonathan Rascher |
Subject: |
Re: Shell exits after process substitution when using DEBUG trap with extdebug |
Date: |
Tue, 4 Aug 2020 09:29:32 -0500 |
On Tue, Aug 4, 2020 at 9:20 AM Chet Ramey <chet.ramey@case.edu> wrote:
> On 8/3/20 9:44 PM, Jonathan Rascher wrote:
> > $ bash --version
> > GNU bash, version 5.0.3(1)-release (x86_64-pc-linux-gnu)
> >
> > $ uname -a
> > Linux penguin 5.4.40-04224-g891a6cce2d44 #1 SMP PREEMPT Tue Jun 23
> 20:21:29
> > PDT 2020 x86_64 GNU/Linux
> >
> > (This is a Pixelbook running the default Crostini Linux VM under Chrome
> > OS 84.0.4147.110. I can reproduce the issue on regular Debian too,
> though.)
> >
> > To reproduce, run the following commands:
> >
> > shopt -s extdebug
> > trap : DEBUG
> > : < <(:)
>
> Thanks for the report. I can't reproduce this with macOS, but I can with
> RHEL 7. I'll take a look.
>
Thanks!
The EOF hunch made me decide to see what happened with ignoreeof set. Sure
enough, instead of exiting when I type the first character after the
command with the process substitution, bash just prints `Use "exit" to
leave the shell.` And then the character I actually typed is still echoed
to the console, and I can keep using the shell. (It doesn't exit if
ignoreeof is set.)
Cheers,
Jon