[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Bash-4.3 Official Patch 25
From: |
Greg Wooledge |
Subject: |
Re: Bash-4.3 Official Patch 25 |
Date: |
Fri, 26 Sep 2014 08:05:45 -0400 |
User-agent: |
Mutt/1.4.2.3i |
On Thu, Sep 25, 2014 at 07:58:56PM -0400, Chet Ramey wrote:
> We used to do that, and part of the code that I removed in patch 25
> supported the original `name()=() {'. We didn't use that very long; it
> turns out that the Bourne shell (and others, at that time) dumps core on
> malformed environment variable names. It's why we stuck with shell
> identifiers, though the check for that didn't come in until later.
>
> I'd be willing to bet that the Bourne shell that still runs on Solaris,
> AIX, HP-UX, and SCO (if anyone still runs that) has this problem.
HP-UX 10.20 (which is from 1994, and was end-of-lifed many years ago)
only has a Bourne shell in /usr/old/bin/sh. It's not used in normal
operations. The /bin/sh on HP-UX is basically a stripped-down ksh.
Unfortunately it's a bit tricky to test whether the Bourne shell would
dump core on a malformed environment variable, because /usr/bin/env
refuses to put such a thing into the environment:
imadev:~$ env 'name()=() {' /usr/old/bin/sh -c 'echo hello'
name()=() {: is not an identifier
I'm not in the mood to write a C program to work around that.
While I haven't used AIX in a long time, the versions I used in the
mid-1990s did not have a Bourne shell either. Almost all the OS vendor
scripts on AIX use ksh anyway. The whole OS is very ksh-centric.
Re: Bash-4.3 Official Patch 25, Jason Vas Dias, 2014/09/25