fcron: optimize start script a bit

This commit is contained in:
Juergen Daubert 2015-10-05 13:06:28 +02:00
parent 9c28d84ea2
commit 8bf44114ae
3 changed files with 9 additions and 4 deletions

View File

@ -1,3 +1,3 @@
50b4de0f8bbbaccb87de9157e391a8e6 fcron
7b83466279d19654fc7f6d259439cd33 fcron
4b031c2fba32a98fa814d1557158b0e9 fcron-3.2.0.src.tar.gz
0153ce1b5ac57ab970abafbde26a9b62 systab.orig

View File

@ -5,7 +5,7 @@
name=fcron
version=3.2.0
release=3
release=4
source=(http://fcron.free.fr/archives/$name-$version.src.tar.gz
fcron systab.orig)

View File

@ -11,12 +11,14 @@ OPTS="--background"
case $1 in
start)
$SSD --start --pidfile $PID --exec $PROG -- $OPTS
if [ ! -f /var/spool/fcron/systab ]; then
/usr/bin/fcrontab -u systab -z
RETVAL=$?
if [ $RETVAL -eq 0 && ! -f /var/spool/fcron/systab ]; then
/usr/bin/fcrontab -u systab -z
fi
;;
stop)
$SSD --stop --retry 10 --pidfile $PID
RETVAL=$?
;;
restart)
$0 stop
@ -24,6 +26,7 @@ restart)
;;
reload)
$SSD --stop --signal USR1 --pidfile $PID
RETVAL=$?
;;
status)
$SSD --status --pidfile $PID
@ -39,4 +42,6 @@ status)
;;
esac
exit $RETVAL
# End of file