Re: local failure

2020-06-01 Thread Greg Wooledge
On Sun, May 31, 2020 at 11:57:03PM -0400, John Passaro wrote: > I think the underlying question here is not exactly "how do I gather this > from the docs" as much as it is "how was I supposed to know about this and > act on it before I had to debug it?" I don't believe the bash documentation is th

Re: Seg fault on "echo ~nosuchuser"

2020-06-01 Thread Chet Ramey
On 5/29/20 2:50 PM, Keith Thompson wrote: >> Can you try this with the current devel branch head from savannah? I >> have a suspicion about what's going on. >> >> http://git.savannah.gnu.org/cgit/bash.git/snapshot/bash-devel.tar.gz > > This did not reproduce the bug. > > $ ./bash --version > GNU

Re: RMS looking for assistance

2020-06-01 Thread Chet Ramey
On 5/31/20 3:03 AM, Stephane Chazelas wrote: > 2020-05-27 10:19:35 -0400, Chet Ramey: >> Richard Stallman is looking for a shell programmer to assist with >> modifying a relatively complex script he uses to process messages and >> access a specific URL. The script is in perl, but he is worried abou

Re: bash errexit shell option does not work in some cases.

2020-06-01 Thread Eli Schwartz
On 6/1/20 6:28 AM, Robert Elz wrote: > Date:Sun, 31 May 2020 22:46:48 -0400 > From:Eli Schwartz > Message-ID: <5a7df0ba-3ad1-1f35-1107-09fdd5950...@archlinux.org> > > While I generally agree with ... > > | Don't use errexit > > but not really with: > > | it doe

Re: binfalse is set to true in the lastpipe test

2020-06-01 Thread Chet Ramey
On 5/31/20 11:25 AM, Pierre Labastie wrote: > Bash Version: 5.0 > Patch Level: 11 > Release Status: release > > Description: > Running tests in the chroot environment of the linuxfromscratch book. > the run-lastpipe test outputs: > 9c9 > < 0 -- 0 0 0 > --- > >

Re: test -v with array elements

2020-06-01 Thread Chet Ramey
On 5/29/20 4:00 PM, Luiz Angelo Daros de Luca wrote: > Hello, > > While using test -v, I noticed that it returns false when I use it > with a sparse or empty array. I need to add [@] or [index] to have it > return true. > > Is this expected? If so, it is not documented. It only has: > > "True if

Re: bash errexit shell option does not work in some cases.

2020-06-01 Thread Chet Ramey
On 5/31/20 10:32 PM, Hyunho Cho wrote: > > GNU bash, version 5.0.16(1)-release (x86_64-pc-linux-gnu) > Operating System: Ubuntu 20.04 LTS > Kernel: Linux 5.4.0-33-generic > Architecture: x86-64 > > > bash errexit shell option does not work in some cases. > after execution a command, exitcode

Re: Unexpected history expanded in heredoc in $() or <()

2020-06-01 Thread Chet Ramey
On 5/29/20 11:59 AM, ladyrick wrote: > Bash Version: 4.4 > Patch Level: 12 > Release Status: release > > > Description: > A heredoc starts with "cat <<'EOF'" is expected to not expand anything > just like in a single quote string. But when this heredoc is in a $() or <(), > history is ex

Re: Seg fault on "echo ~nosuchuser"

2020-06-01 Thread Keith Thompson
On Mon, Jun 1, 2020 at 6:05 AM Chet Ramey wrote: > On 5/29/20 2:50 PM, Keith Thompson wrote: > > >> Can you try this with the current devel branch head from savannah? I > >> have a suspicion about what's going on. > >> > >> http://git.savannah.gnu.org/cgit/bash.git/snapshot/bash-devel.tar.gz > >

Re: Seg fault on "echo ~nosuchuser"

2020-06-01 Thread Chet Ramey
On 6/1/20 3:04 PM, Keith Thompson wrote: > OK, that's half of it. > > If you have a chance, can you verify that the problem exists with the > bash-20200520 push? > > > http://git.savannah.gnu.org/cgit/bash.git/snapshot/bash-ce1a3c07c4e17ed176edccd75892dfcf8242de60.tar.gz > > >

Arithmetic expansion in rediretion word is evaluated twice

2020-06-01 Thread Oğuz
See: $ unset foo $ : <$((foo+=42)) bash: 84: No such file or directory $ echo $foo 84 Reproducible on 4.4.20 and 5.0.11, couldn't try on development version because since the last push it doesn't compile -- Oğuz

Re: Seg fault on "echo ~nosuchuser"

2020-06-01 Thread Keith Thompson
On Mon, Jun 1, 2020 at 12:12 PM Chet Ramey wrote: > > On 6/1/20 3:04 PM, Keith Thompson wrote: > > > OK, that's half of it. > > > > If you have a chance, can you verify that the problem exists with the > > bash-20200520 push? > > > > > > http://git.savannah.gnu.org/cgit/bash.git/s

Re: Arithmetic expansion in rediretion word is evaluated twice

2020-06-01 Thread Chet Ramey
On 6/1/20 3:34 PM, Oğuz wrote: > See: > > $ unset foo > $ : <$((foo+=42)) > bash: 84: No such file or directory > $ echo $foo > 84 > > Reproducible on 4.4.20 and 5.0.11, couldn't try on development version > because since the last push it doesn't compile How about an error me

Arithmetic expansion in rediretion word is evaluated twice

2020-06-01 Thread Oğuz
1 Haziran 2020 Pazartesi tarihinde Chet Ramey yazdı: > On 6/1/20 3:34 PM, Oğuz wrote: > > See: > > > > $ unset foo > > $ : <$((foo+=42)) > > bash: 84: No such file or directory > > $ echo $foo > > 84 > > > > Reproducible on 4.4.20 and 5.0.11, couldn't try on development versio

Re: Seg fault on "echo ~nosuchuser"

2020-06-01 Thread Ángel
On 2020-06-01 at 15:12 -0400, Chet Ramey wrote: > I finally found a case where 16-byte alignment for memory returned by > malloc() is required. But it's only on Linux systems that use systemd. > I bet it's trying to marshal arguments for IPC and uses instructions > that require 16-byte alignment. >

Re: Arithmetic expansion in rediretion word is evaluated twice

2020-06-01 Thread Oğuz
Below is the error message from the compilation failure after git pull && make: variables.o: In function `get_urandom': /home/oguz/.local/src/bash/variables.c:1406: undefined reference to `get_urandom32' variables.o: In function `assign_random': /home/oguz/.local/src/bash/variables.c:1356: undefin