From: Vincent Bernat Date: Sun, 14 Dec 2008 09:38:02 +0000 (+0000) Subject: Execute cron job only if the directory to clean exists. X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=05996740c65b219410864286a816e60a661453c9;p=roundcube.git Execute cron job only if the directory to clean exists. --- diff --git a/debian/changelog b/debian/changelog index 3f55da6..5a69d33 100644 --- a/debian/changelog +++ b/debian/changelog @@ -2,8 +2,9 @@ roundcube (0.2~alpha-4) UNRELEASED; urgency=low * Add missing ${misc:Depends} to make Lintian happy. * Add description to each patch. + * Execute cron job only if the directory to clean exists. - -- Vincent Bernat Sat, 13 Dec 2008 14:53:23 +0100 + -- Vincent Bernat Sun, 14 Dec 2008 10:37:47 +0100 roundcube (0.2~alpha-3) experimental; urgency=high diff --git a/debian/roundcube-core.cron.daily b/debian/roundcube-core.cron.daily index 0fe51fc..ec4bfd7 100644 --- a/debian/roundcube-core.cron.daily +++ b/debian/roundcube-core.cron.daily @@ -6,4 +6,6 @@ if [ -r /etc/default/roundcube-core ]; then . /etc/default/roundcube-core fi -find /var/lib/roundcube/temp -type f -mtime +$MAX_TMPFILE_LIFETIME -print0 | xargs -0 -r rm +if [ -d /var/lib/roundcube/temp ]; then + find /var/lib/roundcube/temp -type f -mtime +$MAX_TMPFILE_LIFETIME -print0 | xargs -0 -r rm +fi