Greetings:

I discovered today that the GROUPS variable is special in Bash.

I moved some scripts to a new box, and they stopped working.  On this
box, /bin/sh linked to /bin/bash instead instead of /bin/dash.

Scripts of of this form...

  #!/bin/sh
  GROUPS='foo bar'
  # do something with $GROUPS here

had worked because GROUPS had no special meaning under /bin/dash.

The script is invoked with /bin/sh (linked to /bin/bash), so I had
expected Bash POSIX compliance to take over.  It did not.

Is this considered a bug?

Should bash, invoked with "--posix" or as "sh", omit the special
treatment of variables such as GROUPS?

-- 
Jason Franklin


Reply via email to