Bug#331299: exim4: bashisms in init script

Adam D. Barratt debian-bts at adam-barratt.org.uk
Sun Oct 2 22:40:29 UTC 2005


On Sun, 2005-10-02 at 17:31 -0400, Justin Pryzby wrote:
> Package: exim4
> Severity: normal
> Version: 4.52-1
> File: /etc/init.d/exim4
> 
> The exim4 initscript /etc/init.d/exim4 uses:
> 
> #!/bin/sh
[...]
>     if [ "$(readlink /proc/$pid/root)" == "/" ]; then
[...]
> Isn't '$(' a bashism (That's what the vim maintainer said in #319825)

No, $() should be supported by any POSIX-compliant shell; it's a "shall"
in the standard. See
http://www.opengroup.org/onlinepubs/009695399/utilities/xcu_chap02.html#tag_02_06_03

The ==, otoh, *is* non-compliant and a Bashism.

Regards,

Adam




More information about the Pkg-exim4-maintainers mailing list