bash 4.4 infinite loop while handling SIGTTIN

2016-11-28 Thread pasthelod
Hello, I'm using this package: bash_4.4-2ubuntu1_amd64.deb ( http://de.archive.ubuntu.com/ubuntu/pool/main/b/bash/bash_4.4-2ubuntu1_amd64.deb ), but the same behavior happens with bash 4.3. This seems to be the bug (feature?):

bash 4.3 completion leak

2016-11-28 Thread Mihail Konev
When bash 4.3 is ran in a terminal emulator, and file completions gathering is in progress, and the emulator is forcefully closed, bash process wouldn't terminate. Instead, it would forever leak memory and cpu. Sorry but I'm not going to bisect this. Ever.

Re: Could bash do what make does?

2016-11-28 Thread Eduardo Bustamante
Why should bash do what make already does?

Re: [Bash 4.4.5] Variable indirection, error on empty variable

2016-11-28 Thread konsolebox
On Mon, Nov 28, 2016 at 5:03 PM, Otenba wrote: >>It is indeed an error to attempt to perform indirection on an empty or >> unset parameter. > What I showed was that it is an error only for an empty parameter. If it's > unset then it will do what it did in Bash 4.3, which is

Re: Could bash do what make does?

2016-11-28 Thread Dennis Williamson
On Sun, Nov 27, 2016 at 7:25 PM, Robert Durkacz wrote: > Has thought been given, over the years, to extending bash to do > what make does, in the obvious way that I am about to describe? > > It would be a matter of having chosen build commands do nothing if their >

Re: Not operator (~) fail on arithmetic expansion.

2016-11-28 Thread Greg Wooledge
On Sun, Nov 27, 2016 at 09:54:59PM -0800, L A Walsh wrote: > Does ~ get home dirs for UID's? I thought it only worked > for usernames? imadev:~$ id uid=563(wooledg) gid=22(pgmr) groups=1002(webauth),208(opgmr) imadev:~$ echo ~563 ~563

Re: Not operator (~) fail on arithmetic expansion.

2016-11-28 Thread Eric Blake
On 11/27/2016 11:54 PM, L A Walsh wrote: > Does ~ get home dirs for UID's? I thought it only worked > for usernames? I would think that allowing user names that were > all numeric would be confusing for software that accept either UID's or > usernames. Can usernames even begin with a number?

Re: bashbug install mode

2016-11-28 Thread Chet Ramey
On 11/27/16 1:35 AM, Michał Górny wrote: > Hi, > > While scanning our systems for executables that are installed u-w, I've > noticed this specific mode is used for bashbug explicitly. Is there > a good reason for doing that? Well, twenty years ago when the two installation modes were introduced,

Re: ``read -N n -t timeout'' saves partial input only when EOF is seen?

2016-11-28 Thread Chet Ramey
On 11/27/16 3:47 PM, Dmitry Goncharov wrote: > On Fri, Nov 25, 2016 at 12:40:58PM -0500, Chet Ramey wrote: >> On 11/25/16 9:57 AM, Dmitry Goncharov wrote: >>> Auto variables have unspecified values after a call to longjmp. >> >> This is true. It's what the USE_VAR macro is intended to defeat, but

Re: bashbug install mode

2016-11-28 Thread Michał Górny
On Mon, 28 Nov 2016 13:25:12 -0800 Chet Ramey wrote: > On 11/27/16 1:35 AM, Michał Górny wrote: > > Hi, > > > > While scanning our systems for executables that are installed u-w, I've > > noticed this specific mode is used for bashbug explicitly. Is there > > a good reason

Re: bash 4.4 infinite loop while handling SIGTTIN

2016-11-28 Thread Chet Ramey
On 11/28/16 4:11 AM, pasthe...@gmail.com wrote: > Hello, > > I'm using this package: bash_4.4-2ubuntu1_amd64.deb ( > http://de.archive.ubuntu.com/ubuntu/pool/main/b/bash/bash_4.4-2ubuntu1_amd64.deb > ), but the same behavior happens with bash 4.3. > > This seems to be the bug (feature?): >

Re: bash 4.3 completion leak

2016-11-28 Thread Chet Ramey
On 11/28/16 5:04 AM, Mihail Konev wrote: > When bash 4.3 is ran in a terminal emulator, and file completions > gathering is in progress, and the emulator is forcefully closed, > bash process wouldn't terminate. > Instead, it would forever leak memory and cpu. This was fixed in bash-4.4. --

Re: bashbug install mode

2016-11-28 Thread Chet Ramey
On 11/28/16 1:35 PM, Michał Górny wrote: > I don't think they do that anymore. Today, the de facto recommendation > from GNU would be automake, which installs all executables 0755. Here bash > stands out as doing something possibly wrong. I disagree that it's wrong, per se. Certainly there's no

Re: here-documents in $(command) substitution

2016-11-28 Thread Chet Ramey
On 11/27/16 2:12 AM, Alexey Tourbin wrote: > Bash Version: 4.4 > Patch Level: 0 > Release Status: release > > Description: > Handling of here-documents in command substitution seems to be inconsistent. > > $ cat test.sh > export foo=$(cat < echo bar > EOF) > echo baz > > $ bash test.sh >

Re: here-documents in $(command) substitution

2016-11-28 Thread Chet Ramey
On 11/27/16 9:51 AM, Eduardo Bustamante wrote: > Delimiter (in your case the three character string "EOF"), has to be > on its own line, with no leading or trailing blanks (or any other > characters). If bash 3.x used to behave different, it's because it was > buggy. Not exactly. Bash has

Re: Not operator (~) fail on arithmetic expansion.

2016-11-28 Thread Chet Ramey
On 11/27/16 12:33 PM, Bize Ma wrote: > Bash Version: 4.4 > Patch Level: 5 > Release Status: release > > Description: > The ~ operator is called not, and does a one's complement of the > following value. That works correctly with > >$ echo $(( ~1 )) >-2 > > Even with > >

Re: [PATCH] Readline not being able to handle long lines

2016-11-28 Thread Chet Ramey
On 11/27/16 2:33 PM, Mihail Konev wrote: > Configuration Information: > OS: Happens both under Linux and MSYS2 (i.e. Cygwin), both 32 and 64 bit I can't reproduce this with any recent version of bash. -- ``The lyf so short, the craft so long to lerne.'' - Chaucer ``Ars longa,

Re: [PATCH] Readline not being able to handle long lines

2016-11-28 Thread Mihail Konev
On Mon, Nov 28, 2016 at 02:02:53PM -0800, Chet Ramey wrote: > On 11/27/16 2:33 PM, Mihail Konev wrote: > > Configuration Information: > > OS: Happens both under Linux and MSYS2 (i.e. Cygwin), both 32 and 64 bit > > I can't reproduce this with any recent version of bash. > Just reproduced it on

Re: bash 4.3 completion leak

2016-11-28 Thread Mihail Konev
On Mon, Nov 28, 2016 at 01:39:29PM -0800, Chet Ramey wrote: > On 11/28/16 5:04 AM, Mihail Konev wrote: > > When bash 4.3 is ran in a terminal emulator, and file completions > > gathering is in progress, and the emulator is forcefully closed, > > bash process wouldn't terminate. > > Instead, it

Re: Nonterminating alias

2016-11-28 Thread Chet Ramey
On 11/27/16 1:45 AM, Dan Douglas wrote: > A simpler one this time. Bash 4.4 only. > > $ bash -c $'alias @="eval {\n}"; eval @' > bash: xrealloc: cannot allocate 18446744071562068464 bytes Yeah, I fixed this totally obsure one, too. -- ``The lyf so short, the craft so long to lerne.'' -

Re: Could bash do what make does?

2016-11-28 Thread Robert Durkacz
make has survived all this time but it is not very well accepted today with a lot of competing build systems trying to do better. bash is very secure and moreover the Bourne shell was there first. make is falling out of favour as far as I can see even though it has had a very good run: Kernighan

Re: Not operator (~) fail on arithmetic expansion.

2016-11-28 Thread Andreas Schwab
On Nov 28 2016, John McKown wrote: > Not replying for Chet, who will have the definitive answer, I will say that > I, personally, think that is working as designed. ~ 0 (with space between) > is definitely the "not" operator. But without the middle space, ~0, where

Re: [Bash 4.4.5] Variable indirection, error on empty variable

2016-11-28 Thread Otenba
>It is indeed an error to attempt to perform indirection on an empty or unset >parameter. What I showed was that it is an error only for an empty parameter. If it's unset then it will do what it did in Bash 4.3, which is return an empty string without error. And another possibility is if the