summaryrefslogtreecommitdiff
path: root/etc/daily
diff options
context:
space:
mode:
authorTodd C. Miller <millert@cvs.openbsd.org>2005-03-17 18:16:53 +0000
committerTodd C. Miller <millert@cvs.openbsd.org>2005-03-17 18:16:53 +0000
commita46c23ca104962ff4fa126f60fef8f3221869d04 (patch)
tree3d67f7d281650e88cb29a828c23c0aaeb9bdd46b /etc/daily
parentee0cfb17979ec18bde07ddf7cb6e9fbfc3db18ac (diff)
Don't rmdir .ICE-unix from /tmp or /var/tmp either. OK deraadt@
Diffstat (limited to 'etc/daily')
-rw-r--r--etc/daily16
1 files changed, 9 insertions, 7 deletions
diff --git a/etc/daily b/etc/daily
index 7ca121e3ad4..3e98d05476f 100644
--- a/etc/daily
+++ b/etc/daily
@@ -1,6 +1,6 @@
#!/bin/sh -
#
-# $OpenBSD: daily,v 1.49 2005/03/16 18:29:58 millert Exp $
+# $OpenBSD: daily,v 1.50 2005/03/17 18:16:52 millert Exp $
# From: @(#)daily 8.2 (Berkeley) 1/25/94
#
PATH=/bin:/usr/bin:/sbin:/usr/sbin:/usr/local/bin
@@ -26,18 +26,20 @@ echo ""
echo "Removing scratch and junk files:"
if [ -d /tmp -a ! -L /tmp ]; then
cd /tmp && {
- find -x . \( -path './ssh-*' -o -path './.X11-unix' \) -prune -o \
- -type f -atime +3 -execdir rm -f -- {} \;
+ find -x . \
+ \( -path './ssh-*' -o -path ./.X11-unix -o -path ./.ICE-unix \) \
+ -prune -o -type f -atime +3 -execdir rm -f -- {} \;
find -x . -type d -mtime +1 ! -path ./vi.recover ! -path ./.X11-unix \
- ! -name . -execdir rmdir -- {} \; >/dev/null 2>&1; }
+ ! -path ./.ICE-unix ! -name . -execdir rmdir -- {} \; >/dev/null 2>&1; }
fi
if [ -d /var/tmp -a ! -L /var/tmp ]; then
cd /var/tmp && {
- find -x . \( -path './ssh-*' -o -path './.X11-unix' \) -prune -o \
- ! -type d -atime +7 -execdir rm -f -- {} \;
+ find -x . \
+ \( -path './ssh-*' -o -path ./.X11-unix -o -path ./.ICE-unix \) \
+ -prune -o ! -type d -atime +7 -execdir rm -f -- {} \;
find -x . -type d -mtime +1 ! -path ./vi.recover ! -path ./.X11-unix \
- ! -name . -execdir rmdir -- {} \; >/dev/null 2>&1; }
+ ! -path ./.ICE-unix ! -name . -execdir rmdir -- {} \; >/dev/null 2>&1; }
fi
# Additional junk directory cleanup would go like this: