Date: Tue, 9 Sep 2014 17:03:58 +0000 (UTC) From: Bryan Drewery <bdrewery@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r271321 - head/etc/periodic/daily Message-ID: <201409091703.s89H3wOv073566@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: bdrewery Date: Tue Sep 9 17:03:58 2014 New Revision: 271321 URL: http://svnweb.freebsd.org/changeset/base/271321 Log: Don't cross mount boundaries when cleaning tmp files. Mounting something in /tmp such as a build jail with nullfs mounts for some directories can result in very surprising results the next day. MFC after: 2 weeks Relnotes: yes Modified: head/etc/periodic/daily/110.clean-tmps Modified: head/etc/periodic/daily/110.clean-tmps ============================================================================== --- head/etc/periodic/daily/110.clean-tmps Tue Sep 9 16:57:02 2014 (r271320) +++ head/etc/periodic/daily/110.clean-tmps Tue Sep 9 17:03:58 2014 (r271321) @@ -45,8 +45,8 @@ case "$daily_clean_tmps_enable" in rc=$(for dir in $daily_clean_tmps_dirs do [ ."${dir#/}" != ."$dir" -a -d $dir ] && cd $dir && { - find -d . -type f $args -delete $print - find -d . ! -name . -type d $dargs -delete $print + find -x -d . -type f $args -delete $print + find -x -d . ! -name . -type d $dargs -delete $print } | sed "s,^\\., $dir," done | tee /dev/stderr | wc -l) [ -z "$print" ] && rc=0
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201409091703.s89H3wOv073566>