bin/125855: sh(1) allows for multiline,
non-escaped control structures (and thus isn't POSIX compliant)
Garrett Cooper
gcooper at FreeBSD.org
Tue Jul 22 15:15:15 UTC 2008
On Tue, Jul 22, 2008 at 6:03 AM, Oliver Fromme <olli at lurza.secnetix.de> wrote:
> Actually I think that both bash's and sh's behaviour is
> correct. As far as I can see in the refrenced standard
> sections, there is no requirement that there must be no
> newline character after the reserved word "!". It seems
> to be unspecified.
>
> FWIW, Solaris' POSIX shell (/bin/ksh and /usr/xpg4/bin/sh)
> allows a newline character, so it behaves the same as our
> /bin/sh. (Note that Solaris' /bin/sh is intentionally not
> a POSIX shell, it doesn't know "!" at all.)
>
> Best regards
> Oliver
Oliver,
Ok. That's what I thought when I was reading the OpenGroup spec
again. It's a bit confusing because I think this is a gray area...
I'll see what the POSIX folks say.
Thanks,
-Garrett
More information about the freebsd-standards
mailing list