From owner-freebsd-ports-bugs@FreeBSD.ORG Wed Jun 15 06:00:38 2005 Return-Path: X-Original-To: freebsd-ports-bugs@hub.freebsd.org Delivered-To: freebsd-ports-bugs@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8B20916A41C for ; Wed, 15 Jun 2005 06:00:38 +0000 (GMT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3C68A43D49 for ; Wed, 15 Jun 2005 06:00:38 +0000 (GMT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.3/8.13.3) with ESMTP id j5F60VLn087779 for ; Wed, 15 Jun 2005 06:00:31 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.13.3/8.13.1/Submit) id j5F60V8F087759; Wed, 15 Jun 2005 06:00:31 GMT (envelope-from gnats) Resent-Date: Wed, 15 Jun 2005 06:00:31 GMT Resent-Message-Id: <200506150600.j5F60V8F087759@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-ports-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Andrew McNaughton Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4BA7C16A41C for ; Wed, 15 Jun 2005 05:53:57 +0000 (GMT) (envelope-from andrew@scoop.co.nz) Received: from a2.scoop.co.nz (aurora.scoop.co.nz [202.50.109.205]) by mx1.FreeBSD.org (Postfix) with ESMTP id C593243D49 for ; Wed, 15 Jun 2005 05:53:54 +0000 (GMT) (envelope-from andrew@scoop.co.nz) Received: from a2.scoop.co.nz (localhost [127.0.0.1]) by a2.scoop.co.nz (8.13.3/8.12.11) with ESMTP id j5F5rqBs043379 for ; Wed, 15 Jun 2005 17:53:52 +1200 (NZST) (envelope-from andrew@a2.scoop.co.nz) Received: (from andrew@localhost) by a2.scoop.co.nz (8.13.3/8.12.11/Submit) id j5F5rqVS043378; Wed, 15 Jun 2005 17:53:52 +1200 (NZST) (envelope-from andrew) Message-Id: <200506150553.j5F5rqVS043378@a2.scoop.co.nz> Date: Wed, 15 Jun 2005 17:53:52 +1200 (NZST) From: Andrew McNaughton To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 Cc: Subject: ports/82259: patch to rc.d script for milter-greylist - currently ignores rc.conf variables X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Andrew McNaughton List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Jun 2005 06:00:38 -0000 >Number: 82259 >Category: ports >Synopsis: patch to rc.d script for milter-greylist - currently ignores rc.conf variables >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Wed Jun 15 06:00:30 GMT 2005 >Closed-Date: >Last-Modified: >Originator: Andrew McNaughton >Release: FreeBSD 4.11-RELEASE-p9 i386 >Organization: Scoop Media Ltd >Environment: System: FreeBSD a2.scoop.co.nz 4.11-RELEASE-p9 FreeBSD 4.11-RELEASE-p9 #1: Mon May 16 14:40:36 NZST 2005 andrew@a2.scoop.co.nz:/usr/obj/usr/src-4.10/sys/wal i386 >Description: variables set in the rc.conf file for milter-greylist don't take effect, as the steps in the rc.d script are performed in the wrong order. >How-To-Repeat: Try setting the location of the socket file, pidfile or some such thing in rc.conf. Nothing happens >Fix: The following fix appears to work, but I'm copying other rc.d scripts fairly blindly, without much familiarity with what I'm doing. Someone should check this patch before applying it. --- milter-greylist.sh.orig Wed Jun 15 17:36:41 2005 +++ milter-greylist.sh Wed Jun 15 17:43:04 2005 @@ -13,6 +13,14 @@ # # DO NOT CHANGE THESE DEFAULT VALUES HERE # + +. /usr/local/etc/rc.subr + +name="miltergreylist" +rcvar=`set_rcvar` + +load_rc_config $name + miltergreylist_enable=${miltergreylist_enable-"NO"} miltergreylist_runas=${miltergreylist_runas-"smmsp"} miltergreylist_pidfile=${miltergreylist_pidfile-"/var/run/milter-greylist.pid"} @@ -21,12 +29,8 @@ miltergreylist_flags=${miltergreylist_flags-"-P $miltergreylist_pidfile \ -f $miltergreylist_cfgfile -p $miltergreylist_sockfile -u $miltergreylist_runas"} -. /usr/local/etc/rc.subr -name="miltergreylist" -rcvar=`set_rcvar` command="/usr/local/bin/milter-greylist" -load_rc_config $name run_rc_command "$1" >Release-Note: >Audit-Trail: >Unformatted: