aboutsummaryrefslogtreecommitdiffstats
path: root/package/busybox/files/cron
diff options
context:
space:
mode:
authorJohn Crispin <blogic@openwrt.org>2008-01-28 17:23:22 +0000
committerJohn Crispin <blogic@openwrt.org>2008-01-28 17:23:22 +0000
commit83f31ca4bcba982688dcf4291949695b3fc7971a (patch)
tree1cd3e42f15762918a14eb0cac97e72abad989de1 /package/busybox/files/cron
parent87cb2bc52984aff7f9ad26a18c006cb3182a8904 (diff)
downloadupstream-83f31ca4bcba982688dcf4291949695b3fc7971a.tar.gz
upstream-83f31ca4bcba982688dcf4291949695b3fc7971a.tar.bz2
upstream-83f31ca4bcba982688dcf4291949695b3fc7971a.zip
only start crond if there are files in the crontab
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@10292 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'package/busybox/files/cron')
-rwxr-xr-xpackage/busybox/files/cron1
1 files changed, 1 insertions, 0 deletions
diff --git a/package/busybox/files/cron b/package/busybox/files/cron
index 9bc89d81ca..9a31392717 100755
--- a/package/busybox/files/cron
+++ b/package/busybox/files/cron
@@ -3,6 +3,7 @@
START=50
start () {
+ [ -z $(ls /etc/crontabs/) ] && exit 1
mkdir -p /var/spool/cron
[ -L /var/spool/cron/crontabs ] || ln -s /etc/crontabs /var/spool/cron/crontabs
crond -c /etc/crontabs