From owner-cvs-src@FreeBSD.ORG Sat Nov 1 01:34:47 2003 Return-Path: Delivered-To: cvs-src@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id F353C16A4CE; Sat, 1 Nov 2003 01:34:46 -0800 (PST) Received: from mailman.zeta.org.au (mailman.zeta.org.au [203.26.10.16]) by mx1.FreeBSD.org (Postfix) with ESMTP id B719143F93; Sat, 1 Nov 2003 01:34:44 -0800 (PST) (envelope-from bde@zeta.org.au) Received: from gamplex.bde.org (katana.zip.com.au [61.8.7.246]) by mailman.zeta.org.au (8.9.3p2/8.8.7) with ESMTP id UAA19398; Sat, 1 Nov 2003 20:34:41 +1100 Date: Sat, 1 Nov 2003 20:34:41 +1100 (EST) From: Bruce Evans X-X-Sender: bde@gamplex.bde.org To: Bruce Evans In-Reply-To: <200311010843.hA18hsAg001012@repoman.freebsd.org> Message-ID: <20031101203313.D3593@gamplex.bde.org> References: <200311010843.hA18hsAg001012@repoman.freebsd.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII cc: cvs-src@freebsd.org cc: src-committers@freebsd.org cc: cvs-all@freebsd.org Subject: Re: cvs commit: src/usr.sbin/mtree compare.c X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 01 Nov 2003 09:34:47 -0000 On Sat, 1 Nov 2003, Bruce Evans wrote: > bde 2003/11/01 00:43:54 PST > > FreeBSD src repository > > Modified files: > usr.sbin/mtree compare.c > Log: > Fixed breakage of my world in rev.1.30. #include instead of > depending on namespace pollution in for the declarations of > struct timeval and utimes(). > > Fixed some style bugs in rev.1.30 and some nearby style bugs (mainly > unsorting and missing or extra blank lines). > > Removed a wrong comment that was obtained from NetBSD in rev.1.14. It said > that chflags() reset the times that were set "above" by utimes(), but > utimes wasn't "above" in FreeBSD until rev.1.30, and chflags() does't > actually reset the times. > > Revision Changes Path > 1.31 +9 -13 src/usr.sbin/mtree/compare.c This doesn't fix any of the more fundamental bugs in rev.1.30: - setting modtimes cannot make the times match the spec in general, since we record and compare times in nanoseconds but can only set them in microseconds. - the modtime setting should have been obained from NetBSD for compatibility and correctness. NetBSD (a 2-3 month old version) only sets the modtimes if an the undocumented -t option is specified. It reduces the previous bug by only comparing times in microseconds (or seconds for the non-BSD_4_4 case). - the access time is clobbered by setting it to the modtime. NetBSD also has options to control setting of file flags. Its -i (set schg and/or sappnd) is very incompatible with FreeBSD's -i (indent 4 spaces). Bruce