rpms/mailman/devel mailman-2.1.12-initcleanup.patch, NONE, 1.1 mailman.spec, 1.86, 1.87

Daniel Novotny dnovotny at fedoraproject.org
Wed Oct 7 10:37:56 UTC 2009


Author: dnovotny

Update of /cvs/extras/rpms/mailman/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv7269

Modified Files:
	mailman.spec 
Added Files:
	mailman-2.1.12-initcleanup.patch 
Log Message:
init script cleanup and fixes for LSB compliance (bz#524016)


mailman-2.1.12-initcleanup.patch:
 mailman.in |   23 +++++++++++++++++++----
 1 file changed, 19 insertions(+), 4 deletions(-)

--- NEW FILE mailman-2.1.12-initcleanup.patch ---
diff -up mailman-2.1.12/misc/mailman.in.initcleanup mailman-2.1.12/misc/mailman.in
--- mailman-2.1.12/misc/mailman.in.initcleanup	2009-10-05 09:09:35.000000000 -0400
+++ mailman-2.1.12/misc/mailman.in	2009-10-05 17:53:56.000000000 -0400
@@ -91,6 +91,8 @@ function start()
     then
 	touch /var/lock/subsys/$prog
 	InstallCron
+    else
+        RETVAL=6	
     fi
     echo
     return $RETVAL
@@ -98,6 +100,8 @@ function start()
 
 function stop()
 {
+    if [ -f /var/lock/subsys/$prog ]
+    then
     echo -n $"Shutting down $prog: "
     mailman-update-cfg
     daemon $MAILMANCTL -q stop
@@ -108,6 +112,10 @@ function stop()
 	RemoveCron
     fi
     echo
+    else
+    echo $"$prog already stopped."
+    RETVAL=0
+    fi
     return $RETVAL
 }
 
@@ -135,7 +143,7 @@ case "$1" in
     RETVAL=$?
     ;;
 
-'condrestart')
+'condrestart'|'try-restart')
     $MAILMANCTL -q -u status
     retval=$?
     if [ $retval -eq 0 ]
@@ -146,13 +154,20 @@ case "$1" in
     ;;
 
 'status')
-    $MAILMANCTL -u status
+    output=$($MAILMANCTL -u status)
     RETVAL=$?
+    if [ $RETVAL -eq 3 -a -f /var/lock/subsys/$prog ]
+    then
+        echo $"$prog dead but subsys locked"
+        RETVAL=2
+    else
+        echo $output
+    fi
     ;;
 
 *)
-    echo $"Usage: $prog {start|stop|restart|force-reload|condrestart|status}"
-    RETVAL=3
+    echo $"Usage: $prog {start|stop|restart|force-reload|condrestart|try-restart|status}"
+    RETVAL=2
     ;;
 
 esac


Index: mailman.spec
===================================================================
RCS file: /cvs/extras/rpms/mailman/devel/mailman.spec,v
retrieving revision 1.86
retrieving revision 1.87
diff -u -p -r1.86 -r1.87
--- mailman.spec	28 Jul 2009 10:46:48 -0000	1.86
+++ mailman.spec	7 Oct 2009 10:37:56 -0000	1.87
@@ -1,7 +1,7 @@
 Summary: Mailing list manager with built in Web access
 Name: mailman
 Version: 2.1.12
-Release: 9%{?dist}
+Release: 10%{?dist}
 Epoch: 3
 Group: Applications/Internet
 Source0: ftp://ftp.gnu.org/pub/gnu/mailman/mailman-%{version}.tgz
@@ -32,6 +32,7 @@ Patch15: mailman-2.1.12-lctype.patch
 #Patch15: mailman-2.1.11-footer.patch
 Patch16: mailman-2.1.12-privurl.patch
 Patch17: mailman-2.1.12-mmcfg.patch
+Patch18: mailman-2.1.12-initcleanup.patch
 
 License: GPLv2+
 URL: http://www.list.org/
@@ -118,6 +119,7 @@ additional installation steps, these are
 #%%patch15 -p1 -b .footer
 %patch16 -p1 -b .privurl
 %patch17 -p1 -b .mmcfg
+%patch18 -p1 -b .initcleanup
 
 #cp $RPM_SOURCE_DIR/mailman.INSTALL.REDHAT.in INSTALL.REDHAT.in
 cp %{SOURCE5} INSTALL.REDHAT.in
@@ -485,6 +487,9 @@ exit 0
 %attr(0755,root,root) %{_bindir}/mailman-update-cfg
 
 %changelog
+* Wed Oct 07 2009 Daniel Novotny <dnovotny at redhat.com> 3:2.1.12-10
+- init script cleanup and fixes for LSB compliance (bz#524016)
+
 * Tue Jul 28 2009 Daniel Novotny <dnovotny at redhat.com> 3:2.1.12-9
 - regenerated patches so patch fuzz 3 is not needed (bz#513207)
 - mm_cfg.pyc and .pyo are now %%verify(not md5 size mtime) (bz#512794)




More information about the fedora-extras-commits mailing list