From f4c23600ac2cb1761ee283cc130e0562b962c711 Mon Sep 17 00:00:00 2001 From: Jonas Smedegaard Date: Wed, 11 Jul 2007 22:51:52 +0000 Subject: Fix bashisms. --- postfix/postfix.sh | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/postfix/postfix.sh b/postfix/postfix.sh index e7093a4..f60e2e2 100755 --- a/postfix/postfix.sh +++ b/postfix/postfix.sh @@ -1,9 +1,9 @@ -#!/bin/bash +#!/bin/sh # # /etc/local-COMMON/postfix/postfix.sh # Copyright 2002-2004 Jonas Smedegaard # -# $Id: postfix.sh,v 1.37 2007-07-11 22:49:22 jonas Exp $ +# $Id: postfix.sh,v 1.38 2007-07-11 22:51:52 jonas Exp $ # # Auto-tweak plain installed postfix Debian package # @@ -55,7 +55,7 @@ else fi sasldir="$confdir/sasl" -function catfirstfile() { +catfirstfile() { for dir in $paramdirs; do if [ -d "$dir" ] && [ -f "$dir/$param" ]; then paramdir="$dir" @@ -69,7 +69,7 @@ function catfirstfile() { cat "$paramdir/$param" } -function getlinesfromfile() { +getlinesfromfile() { param="$1" shift replacements= @@ -125,7 +125,7 @@ fi # TLS breaks postfix if no SASL modules available (and doesn't make sense either) # (change the test if using some other modules and avoid the plain ones) -if [ -n "$pftls" -a -n "$sasl2" -a -f /etc/ssl/certs/postfix.pem ]; then +if [ -n "$pftls" [ && [ -n "$sasl2" ] && [ -f /etc/ssl/certs/postfix.pem ]; then mkdir -p "$sasldir" echo 'mech_list: plain login' > "$sasldir/smtpd.conf" echo 'minimum_layer: 0' >> "$sasldir/smtpd.conf" @@ -196,7 +196,7 @@ else echo 'WARNING: TLS not activated - check the script for requirements...' fi -if [ -x /usr/sbin/amavisd -o -x /usr/sbin/amavisd-new ]; then +if [ -x /usr/sbin/amavisd ] || [ -x /usr/sbin/amavisd-new ]; then localtransport="smtp" if [ "$pf2" ]; then # lmtp is slightly buggy in earlier versions localtransport="lmtp" # Provides multi-session mail transaction capability and per-recipient status responses. -- cgit v1.2.3