Word boundary anchors \< and \> not parsed correctly on the right side of =~

2018-07-09 Thread marcelpaulo
Configuration Information [Automatically generated, do not change]: Machine: x86_64 OS: linux-gnu Compiler: gcc Compilation CFLAGS: -DPROGRAM='bash' -DCONF_HOSTTYPE='x86_64' -DCONF_OSTYPE='linux-gnu' -DCONF_MACHTYPE='x86_64-pc-linux-gnu' -DCONF_VENDOR='pc' -DLOCALEDIR='/usr/share/locale' -DPACKA

Re: Number with sign is read as octal despite a leading 10#

2018-07-09 Thread Clint Hepner
The + is a unary operator, not part of the literal. Write $((+10#0034)) instead. -- Clint On Jul 9, 2018, 9:24 PM -0400, Isaac Marcos , wrote: > Configuration Information [Automatically generated, do not change]: > Machine: x86_64 > OS: linux-gnu > Compiler: gcc > Compilation CFLAGS: -DPROGRAM='b

Number with sign is read as octal despite a leading 10#

2018-07-09 Thread Isaac Marcos
Configuration Information [Automatically generated, do not change]: Machine: x86_64 OS: linux-gnu Compiler: gcc Compilation CFLAGS: -DPROGRAM='bash' -DCONF_HOSTTYPE='x86_64' -DCONF_OSTYPE='linux-gnu' -DCONF_MACHTYPE='x86_64-pc-linux-gnu' -DCONF_VENDOR uname output: Linux IO 4.9.0-6-amd64 #1 SMP De

Re: [PATCH] Fix null environ crash in getenv() provided by lib/sh/getenv.c

2018-07-09 Thread Chet Ramey
On 7/8/18 7:21 AM, Keeley Hoek wrote: > In running bash on an embedded target, bash crashes for the silly > reason that environ is NULL. > > I haven't been able to tell whether this is actually permitted by the > standard (as if?), but in bash I think this behavior is inconsistent > anyway because

Re: [PATCH] Use memmove instead of strcpy

2018-07-09 Thread Chet Ramey
On 7/7/18 1:25 AM, Bernhard M. Wiedemann wrote: > In https://bugzilla.opensuse.org/show_bug.cgi?id=1100488 > we found that depending on the build machine, bash-4.4's bash.html would > contain the string Bahh instead of Bash > > strcpy can cause corruption when working on overlapping strings > so