From owner-freebsd-current Thu Apr 26 14:22: 6 2001 Delivered-To: freebsd-current@freebsd.org Received: from earth.backplane.com (earth-nat-cw.backplane.com [208.161.114.67]) by hub.freebsd.org (Postfix) with ESMTP id 8377837B422 for ; Thu, 26 Apr 2001 14:22:04 -0700 (PDT) (envelope-from dillon@earth.backplane.com) Received: (from dillon@localhost) by earth.backplane.com (8.11.2/8.11.2) id f3QLLkE56741; Thu, 26 Apr 2001 14:21:46 -0700 (PDT) (envelope-from dillon) Date: Thu, 26 Apr 2001 14:21:46 -0700 (PDT) From: Matt Dillon Message-Id: <200104262121.f3QLLkE56741@earth.backplane.com> To: "John W. De Boskey" Cc: current@FreeBSD.ORG, Jeroen Ruigrok/Asmodai Subject: Re: cp -u patch References: <20010426222132.B55566@daemon.ninth-circle.org> <20010426171522.A51935@bsdwins.com> Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG :You are one brave soul if the only precedent you have for this :patch is GNU cp. : :Personally, I see nothing wrong with it. : :With respect to how you short circuit the copy if :the mtimes are 'ok', you probably need to return a value :different than 1 so that your caller can distinquish between :a failed copy (badcp = rval = 1) and a skipped copy. : :Thus, the return code from 'cp' will be correct. With your :patch, if the -u option skips a file, the return code from :cp is 1. : :Just my .02 cents, :-John Guys, putting all this piecemeal junk into 'cp' is a waste of effort. Use cpdup if you want to make an efficient, exact copy of a filesystem. You can find it in ports. I'm working on a new version of cpdup that will operate over a stream connection (client/server environment), but it isn't quite ready yet. I also have a few bug fixes almost ready to go out, mainly related to making cpdup work better on files which have been chflags'd. But what is in ports right now works extremely well. -Matt To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message