mirror of https://github.com/fail2ban/fail2ban
use printf instead of echo for POSIX compatibility (issue #1003)
parent
ac1e41ea70
commit
675c3a7c95
|
@ -17,7 +17,7 @@ _whois = whois <ip> || echo "missing whois program"
|
|||
# character set before sending it to a mail program
|
||||
_whois_target_charset = UTF-8
|
||||
_whois_convert_charset = whois <ip> |
|
||||
{ c=$(cat) ; cs=$(echo -ne "$c" | file -b --mime-encoding -) ; echo -ne "$c" | iconv -f $cs -t %(_whois_target_charset)s//TRANSLIT - ; }
|
||||
{ c=$(cat) ; cs=$(printf %%b "$c" | file -b --mime-encoding -) ; printf %%b "$c" | iconv -f $cs -t %(_whois_target_charset)s//TRANSLIT - ; }
|
||||
|
||||
# choose between _whois and _whois_convert_charset in mail-whois-common.local
|
||||
# or other *.local which include mail-whois-common.conf.
|
||||
|
|
Loading…
Reference in New Issue