Gentoo Archives: gentoo-commits

From: "Eray Aslan (eras)" <eras@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in mail-filter/amavisd-new/files: amavisd.initd
Date: Tue, 10 Jan 2012 13:46:57
Message-Id: 20120110134647.AA6AB2004C@flycatcher.gentoo.org
1 eras 12/01/10 13:46:47
2
3 Modified: amavisd.initd
4 Log:
5 don't try to parse the config file - bug #397763
6
7 (Portage version: 2.1.10.44/cvs/Linux x86_64)
8
9 Revision Changes Path
10 1.4 mail-filter/amavisd-new/files/amavisd.initd
11
12 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/mail-filter/amavisd-new/files/amavisd.initd?rev=1.4&view=markup
13 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/mail-filter/amavisd-new/files/amavisd.initd?rev=1.4&content-type=text/plain
14 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/mail-filter/amavisd-new/files/amavisd.initd?r1=1.3&r2=1.4
15
16 Index: amavisd.initd
17 ===================================================================
18 RCS file: /var/cvsroot/gentoo-x86/mail-filter/amavisd-new/files/amavisd.initd,v
19 retrieving revision 1.3
20 retrieving revision 1.4
21 diff -u -r1.3 -r1.4
22 --- amavisd.initd 6 Jan 2012 11:38:35 -0000 1.3
23 +++ amavisd.initd 10 Jan 2012 13:46:47 -0000 1.4
24 @@ -1,14 +1,13 @@
25 #!/sbin/runscript
26 # Copyright 1999-2012 Gentoo Foundation
27 # Distributed under the terms of the GNU General Public License v2
28 -# $Header: /var/cvsroot/gentoo-x86/mail-filter/amavisd-new/files/amavisd.initd,v 1.3 2012/01/06 11:38:35 eras Exp $
29 +# $Header: /var/cvsroot/gentoo-x86/mail-filter/amavisd-new/files/amavisd.initd,v 1.4 2012/01/10 13:46:47 eras Exp $
30
31 extra_started_commands="reload"
32 extra_commands="debug debug_sa"
33
34 prog="/usr/sbin/amavisd"
35 progname="amavisd-new"
36 -conffile="/etc/amavisd.conf"
37
38 depend() {
39 need net
40 @@ -16,23 +15,8 @@
41 before mta
42 }
43
44 -checkconfig() {
45 - local piddir pidfile
46 - if [ -r "${conffile}" ] ; then
47 - pidfile=$(grep -m1 ^[^#].*pid_file "${conffile}"|sed -e 's/.*"\(.*\)".*/\1/')
48 - piddir=${pidfile%/*}
49 - if [ ! -d "${piddir:=/var/amavis}" ] ; then
50 - checkpath -q -d -o root:amavis -m 0770 "${piddir}" || return 1
51 - fi
52 - else
53 - eerror "Missing conf file."
54 - return 1
55 - fi
56 -}
57 -
58 start() {
59 ebegin "Starting ${progname}"
60 - checkconfig || return 1
61 "${prog}" start
62 eend $?
63 }
64 @@ -59,14 +43,12 @@
65
66 debug() {
67 ebegin "Starting ${progname} in debug mode"
68 - checkconfig || return 1
69 "${prog}" debug
70 eend $?
71 }
72
73 debug_sa() {
74 ebegin "Starting ${progname} in debug-sa mode"
75 - checkconfig || return 1
76 "${prog}" debug-sa
77 eend $?
78 }