drizzt@ITVIMN0I35793 dante % checkbashisms.pl -f files/dante-sockd-init possible bashism in files/dante-sockd-init line 25 (should be >word 2>&1): /usr/sbin/sockd -V &> /tmp/dante-sockd.checkconf possible bashism in files/dante-sockd-init line 47 (should be >word 2>&1): --make-pidfile --exec /usr/sbin/sockd -- ${SOCKD_OPT} &> /dev/null drizzt@ITVIMN0I35793 dante %
Fixed in dante-1.1.19-r3.
Short version: please change "2>&1 >file" to ">file 2>&1". Long version: http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-proxy/dante/files/dante-sockd-init?r1=1.4&r2=1.5 changes "&> file" to "2>&1 >file" which is probably incorrect. "&> file" redirects both standard output and standard error to the target file, while "2>&1 >file" redirects standard error to what previously was standard output, and standard output only to the file. As a result, error messages from the process will not end up in the file, but on standard output. To get the behaviour of "&> file" you should use ">file 2>&1", i.e. change the order. That way, you will redirect standard output to the file first, and then redirect standard error to what standard output is currently pointing to, i.e. the same file. To test this on the command line: $ ( echo error 1>&2 ) 2>&1 >/dev/null error $ ( echo error 1>&2 ) >/dev/null 2>&1
Damn shell language! Fixed in in dante-1.1.19-r4, thanks for pointing out my mistake.