]> git.pld-linux.org Git - packages/syslog-ng.git/commitdiff
- do not restart the upstart service twice
authorJacek Konieczny <jajcus@pld-linux.org>
Tue, 11 May 2010 15:50:50 +0000 (15:50 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    syslog-ng.spec -> 1.187

syslog-ng.spec

index 11197fa721b846872c8edefd97d02133c16da281..b59e8926393a8e487e324a8985fc1677bd56f50a 100644 (file)
@@ -10,7 +10,7 @@ Summary(pl.UTF-8):    Syslog-ng - zamiennik syskloga
 Summary(pt_BR.UTF-8):  Daemon de log nova geração
 Name:          syslog-ng
 Version:       3.0.5
-Release:       3
+Release:       3.6
 License:       GPL v2
 Group:         Daemons
 Source0:       http://www.balabit.com/downloads/files/syslog-ng/sources/%{version}/source/%{name}_%{version}.tar.gz
@@ -81,15 +81,15 @@ BuildRoot:  %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
        if [ -f /var/lock/subsys/"%1" ] ; then \
                /sbin/service --no-upstart "%1" stop \
                /sbin/service "%1" start \
-       else \
-               /sbin/service "%1" try-restart \
        fi
 
 # restart the job after upgrade or migrate to init script on removal
+# cannot be stopped with 'service' as /etc/init/$name.conf may be missing
+# at this point
 %define        upstart_postun() \
        if [ -x /sbin/initctl ] && /sbin/initctl status "%1" 2>/dev/null | grep -q 'running' ; then \
-               /sbin/initctl stop "%1" 2>/dev/null \
-               [ -f "/etc/rc.d/init.d/%1" -o -f "/etc/init/%1.conf" ] && /sbin/service "%1" start \
+               /sbin/initctl stop "%1" >/dev/null 2>&1 \
+               [ -f "/etc/rc.d/init.d/%1" -o -f "/etc/init/%1.conf" ] && { echo -n "Re-" ; /sbin/service "%1" start ; } ; \
        fi
 
 %description
This page took 0.080456 seconds and 4 git commands to generate.