From owner-freebsd-bugs Fri Jun 22 16:20:11 2001 Delivered-To: freebsd-bugs@hub.freebsd.org Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by hub.freebsd.org (Postfix) with ESMTP id 5855837B409 for ; Fri, 22 Jun 2001 16:20:02 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.11.3/8.11.3) id f5MNK2A84050; Fri, 22 Jun 2001 16:20:02 -0700 (PDT) (envelope-from gnats) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by hub.freebsd.org (Postfix) with ESMTP id EF54E37B406 for ; Fri, 22 Jun 2001 16:10:44 -0700 (PDT) (envelope-from nobody@FreeBSD.org) Received: (from nobody@localhost) by freefall.freebsd.org (8.11.3/8.11.3) id f5MNAiQ83423; Fri, 22 Jun 2001 16:10:44 -0700 (PDT) (envelope-from nobody) Message-Id: <200106222310.f5MNAiQ83423@freefall.freebsd.org> Date: Fri, 22 Jun 2001 16:10:44 -0700 (PDT) From: NIIMI Satoshi To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-1.0 Subject: misc/28355: /etc/periodic/daily/110.clean-tmps reports incorrect result Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org >Number: 28355 >Category: misc >Synopsis: /etc/periodic/daily/110.clean-tmps reports incorrect result >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Fri Jun 22 16:20:01 PDT 2001 >Closed-Date: >Last-Modified: >Originator: NIIMI Satoshi >Release: FreeBSD 4.3-STABLE i386 >Organization: >Environment: FreeBSD berkeley.us.and.or.jp 4.3-STABLE FreeBSD 4.3-STABLE #2: Thu Jun 21 18:28:33 JST 2001 sa2c@berkeley.us.and.or.jp:/usr/obj/usr/src/sys/BERKELEY i386 >Description: /etc/periodic/daily/110.clean-tmps reports like >How-To-Repeat: Insert 'daily_clean_disks_enable="YES"' in /etc/periodic.conf and type the following commands: mkdir -p /tmp/path/to/dir touch /tmp/path/to/dir/file touch -t 19700102 /tmp/path/to/dir /etc/periodic/daily/110.clean-tmps >Fix: diff -u -r1.10 110.clean-tmps --- 110.clean-tmps 2000/09/14 17:19:10 1.10 +++ 110.clean-tmps 2001/06/22 22:46:34 @@ -41,7 +41,7 @@ do [ ."${dir#/}" != ."$dir" -a -d $dir ] && cd $dir && { find -d . -type f $args -delete $print - find -d . ! -name . -type d -mtime \ + find -d . ! -name . -type d -empty -mtime \ +$daily_clean_tmps_days -delete $print } | sed "s,^\\., $dir," done | tee /dev/stderr | wc -l) >Release-Note: >Audit-Trail: >Unformatted: >Removing old temporary files: > /tmp/path/to/file > /tmp/path/to/dir but if "/tmp/path/to/dir" is directory and is not empy, it is not deleted. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message