From d4eae248fc3499866ff557806dc95e19f9c41643 Mon Sep 17 00:00:00 2001 From: dougb Date: Sun, 15 May 2011 02:49:17 +0000 Subject: Remove painful examples of foo="", with particular prejudice against constructions that parse out to [ -z "$foo" ] && foo="" These are bad examples that get copied and pasted into new code, so the hope is that with less bad examples there will be less need for me to bring this up in review. In a few of these files all that were changed were comments so that next time I search for these patterns I won't trip on the file for no reason. In a few places, add $FreeBSD$ No functional changes, so no PORTREVISION bumps --- mail/archivesmtp/files/archivesmtp.in | 1 - mail/batv-milter/files/milter-batv.sh.in | 5 ----- mail/dkim-milter/files/milter-dkim.sh.in | 6 ------ mail/milter-manager/files/milter-manager.in | 2 -- mail/milter-regex/files/milterregex.sh.in | 3 ++- mail/noattach/files/noattach.sh.in | 3 ++- mail/opendkim/files/milter-opendkim.in | 6 ------ mail/postfix25/files/postfix.sh.in | 1 - mail/qmail/files/qmail-smtpd.rcNG | 5 ++++- mail/sa-utils/files/sa-utils.in | 3 --- mail/spamilter/files/spamilter.sh.in | 3 ++- mail/vbsfilter/files/vbsfilter.sh.in | 3 ++- 12 files changed, 12 insertions(+), 29 deletions(-) (limited to 'mail') diff --git a/mail/archivesmtp/files/archivesmtp.in b/mail/archivesmtp/files/archivesmtp.in index 97d85084d720..6463f1c320d7 100644 --- a/mail/archivesmtp/files/archivesmtp.in +++ b/mail/archivesmtp/files/archivesmtp.in @@ -18,7 +18,6 @@ load_rc_config "$name" : ${archivesmtp_socket="unix:%%SOCKETBASE%%/%%SOCKETDIR%%/mta.sock"} : ${archivesmtp_config="%%PREFIX%%/etc/archivesmtp.conf"} : ${archivesmtp_pidfile="%%SOCKETBASE%%/%%SOCKETDIR%%/run.pid"} -: ${archivesmtp_flags=""} pidfile="${archivesmtp_pidfile}" diff --git a/mail/batv-milter/files/milter-batv.sh.in b/mail/batv-milter/files/milter-batv.sh.in index 852a72a1d994..8fdaee60c9dd 100644 --- a/mail/batv-milter/files/milter-batv.sh.in +++ b/mail/batv-milter/files/milter-batv.sh.in @@ -48,13 +48,8 @@ load_rc_config $name # : ${milterbatv_enable="NO"} : ${milterbatv_uid="mailnull"} -: ${milterbatv_profiles=""} : ${milterbatv_cfgfile="%%PREFIX%%/etc/mail/batv-filter.conf"} -: ${milterbatv_socket=""} -: ${milterbatv_domain=""} -: ${milterbatv_allowlist=""} -: ${milterbatv_key=""} # Options other than above can be set with $milterbatv_flags. # see batv-milter documentation for detail. diff --git a/mail/dkim-milter/files/milter-dkim.sh.in b/mail/dkim-milter/files/milter-dkim.sh.in index 0165031f1781..bb3eca82c4bc 100644 --- a/mail/dkim-milter/files/milter-dkim.sh.in +++ b/mail/dkim-milter/files/milter-dkim.sh.in @@ -49,14 +49,8 @@ load_rc_config $name # : ${milterdkim_enable="NO"} : ${milterdkim_uid="mailnull"} -: ${milterdkim_profiles=""} : ${milterdkim_cfgfile="%%PREFIX%%/etc/mail/dkim-filter.conf"} -: ${milterdkim_socket=""} -: ${milterdkim_domain=""} -: ${milterdkim_key=""} -: ${milterdkim_selector=""} -: ${milterdkim_alg=""} # Options other than above can be set with $milterdkim_flags. # see dkim-milter documentation for detail. diff --git a/mail/milter-manager/files/milter-manager.in b/mail/milter-manager/files/milter-manager.in index 06971055baac..d1b77bcbedb4 100644 --- a/mail/milter-manager/files/milter-manager.in +++ b/mail/milter-manager/files/milter-manager.in @@ -48,12 +48,10 @@ load_rc_config $name # DO NOT CHANGE THESE DEFAULT VALUES HERE # : ${miltermanager_enable="NO"} -: ${miltermanager_profiles=""} : ${miltermanager_cfgdir="%%PREFIX%%/etc/milter-manager"} : ${miltermanager_uid="mailnull"} : ${miltermanager_gid="mail"} : ${miltermanager_socket_gid="mail"} -: ${miltermanager_socket=""} : ${miltermanager_debug="NO"} # Options other than above can be set with $miltermanager_flags. # see milter-manager documentation for detail. diff --git a/mail/milter-regex/files/milterregex.sh.in b/mail/milter-regex/files/milterregex.sh.in index 74d0a72f25cf..0ee9590577ed 100644 --- a/mail/milter-regex/files/milterregex.sh.in +++ b/mail/milter-regex/files/milterregex.sh.in @@ -18,8 +18,9 @@ spooldir=%%SPOOLDIR%% # # DO NOT CHANGE THESE DEFAULT VALUES HERE # +# milterregex_flags Flags to milter-regex program + [ -z "$milterregex_enable" ] && milterregex_enable="NO" # Enable milter-regex -# milterregex_flags="" # Flags to milter-regex program . /etc/rc.subr diff --git a/mail/noattach/files/noattach.sh.in b/mail/noattach/files/noattach.sh.in index 4e32b95f33aa..c11bd3648464 100644 --- a/mail/noattach/files/noattach.sh.in +++ b/mail/noattach/files/noattach.sh.in @@ -17,10 +17,11 @@ # # DO NOT CHANGE THESE DEFAULT VALUES HERE # +# noattach_flags Flags to noattach + noattach_enable=${noattach_enable:-"NO"} # Enable noattach noattach_pidfile=${noattach_pidfile:-"/var/run/noattach.pid"} # Path to pidfile noattach_socket=${noattach_socket:-"/var/run/noattach"} # Path to socket -# noattach_flags="" # Flags to noattach . /etc/rc.subr diff --git a/mail/opendkim/files/milter-opendkim.in b/mail/opendkim/files/milter-opendkim.in index f075bf6c2ef4..a21f95e121a4 100644 --- a/mail/opendkim/files/milter-opendkim.in +++ b/mail/opendkim/files/milter-opendkim.in @@ -51,14 +51,8 @@ load_rc_config $name # : ${milteropendkim_enable="NO"} : ${milteropendkim_uid="mailnull"} -: ${milteropendkim_profiles=""} : ${milteropendkim_cfgfile="%%PREFIX%%/etc/mail/opendkim.conf"} -: ${milteropendkim_socket=""} -: ${milteropendkim_domain=""} -: ${milteropendkim_key=""} -: ${milteropendkim_selector=""} -: ${milteropendkim_alg=""} # Options other than above can be set with $milteropendkim_flags. # see dkim-milter documentation for detail. diff --git a/mail/postfix25/files/postfix.sh.in b/mail/postfix25/files/postfix.sh.in index 3fc9d1dc3706..44aa542f07a8 100644 --- a/mail/postfix25/files/postfix.sh.in +++ b/mail/postfix25/files/postfix.sh.in @@ -28,7 +28,6 @@ load_rc_config $name : ${postfix_enable="NO"} : ${postfix_pidfile="/var/spool/postfix/pid/master.pid"} : ${postfix_procname="%%PREFIX%%/libexec/postfix/master"} -: ${postfix_flags=""} start_cmd=${name}_start stop_cmd=${name}_stop diff --git a/mail/qmail/files/qmail-smtpd.rcNG b/mail/qmail/files/qmail-smtpd.rcNG index 56c17163e019..4497bf4215c6 100644 --- a/mail/qmail/files/qmail-smtpd.rcNG +++ b/mail/qmail/files/qmail-smtpd.rcNG @@ -1,4 +1,6 @@ #!/bin/sh + +# $FreeBSD$ # # PROVIDE: qmailsmtpd # REQUIRE: LOGIN cleanvar @@ -8,6 +10,8 @@ # security/checkpassword or security checkpassword-pam). # # Note: tcpserver can be found in the sysutils/ucspi-tcp package. +# +# qmailsmtpd_checkpassword could be set to e.g. /usr/local/bin/checkpassword-pam . /etc/rc.subr @@ -24,7 +28,6 @@ load_rc_config $name : ${qmailsmtpd_port="smtp"} : ${qmailsmtpd_smtpd="/var/qmail/bin/qmail-smtpd"} : ${qmailsmtpd_fqdn=`hostname`} -: ${qmailsmtpd_checkpassword=""} # e.g. /usr/local/bin/checkpassword-pam : ${qmailsmtpd_checksubprogram="/usr/bin/true"} qmailsmtpd_start() { diff --git a/mail/sa-utils/files/sa-utils.in b/mail/sa-utils/files/sa-utils.in index 49472b92bffc..77a88ecd24c1 100644 --- a/mail/sa-utils/files/sa-utils.in +++ b/mail/sa-utils/files/sa-utils.in @@ -65,11 +65,8 @@ fi : ${daily_sa_enable="YES"} : ${daily_sa_quiet="NO"} -: ${daily_sa_update_flags=""} : ${daily_sa_compile="%%SACOMPILE%%"} -: ${daily_sa_compile_flags=""} : ${daily_sa_compile_nice="YES"} -: ${daily_sa_compile_nice_flags=""} : ${daily_sa_restart_spamd="YES"} PATH=/bin:/sbin:/usr/bin:/usr/sbin:%%LOCALBASE%%/bin:%%LOCALBASE%%/sbin diff --git a/mail/spamilter/files/spamilter.sh.in b/mail/spamilter/files/spamilter.sh.in index 0a1cde8fd371..8ef4f1406e5e 100644 --- a/mail/spamilter/files/spamilter.sh.in +++ b/mail/spamilter/files/spamilter.sh.in @@ -17,8 +17,9 @@ # # DO NOT CHANGE THESE DEFAULT VALUES HERE # +# spamilter_flags Flags to spamilter + spamilter_enable=${spamilter_enable:-"NO"} # Enable spamilter-milter -# spamilter_flags="" # Flags to spamilter . /etc/rc.subr diff --git a/mail/vbsfilter/files/vbsfilter.sh.in b/mail/vbsfilter/files/vbsfilter.sh.in index 5183e486cf56..11302be8bd82 100644 --- a/mail/vbsfilter/files/vbsfilter.sh.in +++ b/mail/vbsfilter/files/vbsfilter.sh.in @@ -17,9 +17,10 @@ # # DO NOT CHANGE THESE DEFAULT VALUES HERE # +# vbsfilter_flags Flags to vbsfilter + vbsfilter_enable=${vbsfilter_enable:-"NO"} # Enable vbsfilter-milter vbsfilter_socket=${vbsfilter_socket:-"/var/run/vbsfilter"} # Path to socket -# vbsfilter_flags="" # Flags to vbsfilter . /etc/rc.subr -- cgit