From owner-svn-src-stable-10@FreeBSD.ORG Sat Oct 4 03:11:10 2014 Return-Path: Delivered-To: svn-src-stable-10@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 475E9F47; Sat, 4 Oct 2014 03:11:10 +0000 (UTC) Received: from mail-pa0-x22c.google.com (mail-pa0-x22c.google.com [IPv6:2607:f8b0:400e:c03::22c]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id F032528C; Sat, 4 Oct 2014 03:11:09 +0000 (UTC) Received: by mail-pa0-f44.google.com with SMTP id et14so2427844pad.31 for ; Fri, 03 Oct 2014 20:11:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=content-type:mime-version:subject:from:in-reply-to:date:cc :message-id:references:to; bh=qnDAyq3iNCuTH8OIX8dkSJI6pQYsK2kAgyM+EpB+Lw0=; b=CeyEY9XQPKMf/pEjQUP6Yf2X3f874CQjl9rypWW02uWGzOV7JMPsjzBo8lAoS7pD/8 xKA4IZYdDoAmp6Edq7l4T5Xm5z3l8gSQU70oBwQODzmRIQmtzJyqd4t0omuk73tkvaCY 0PqErtlNi7VZ9dmXO54UEpoBOK8J4fxEgJ622wPwCaeTzyIYBUBvw1EH/EErZq8YCOMI brgEYIXiZxJ/9JFIkXB6TkxqBGUsU0HXNyt6vWM5/y8hxxmuMV9nbcaDTIBCqR64gb9M q5VdInUfxSmKVK3SkIMVhCqcF1597D4NYlogk+kHpWxZWR62k4/ztvkbr9ptwkWJx0H/ 7emg== X-Received: by 10.66.219.6 with SMTP id pk6mr10827030pac.35.1412392269331; Fri, 03 Oct 2014 20:11:09 -0700 (PDT) Received: from ?IPv6:2601:8:ab80:7d6:44b4:d70:65e5:35a5? ([2601:8:ab80:7d6:44b4:d70:65e5:35a5]) by mx.google.com with ESMTPSA id t11sm5258287pdj.89.2014.10.03.20.11.08 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 03 Oct 2014 20:11:08 -0700 (PDT) Content-Type: multipart/signed; boundary="Apple-Mail=_7CDEB9E0-CF06-451B-971D-D7DC20EFC349"; protocol="application/pgp-signature"; micalg=pgp-sha512 Mime-Version: 1.0 (Mac OS X Mail 7.3 \(1878.6\)) Subject: Re: svn commit: r272372 - stable/10/bin/rm From: Garrett Cooper In-Reply-To: <20141003084842.T998@besplex.bde.org> Date: Fri, 3 Oct 2014 20:11:02 -0700 Message-Id: References: <201410011618.s91GIfR5071251@svn.freebsd.org> <20141002141656.Y1807@besplex.bde.org> <20141002061628.GO1275@hub.FreeBSD.org> <201410021713.57943.jhb@freebsd.org> <20141003084842.T998@besplex.bde.org> To: Bruce Evans X-Mailer: Apple Mail (2.1878.6) Cc: src-committers@freebsd.org, svn-src-stable-10@freebsd.org, John Baldwin , svn-src-stable@freebsd.org, svn-src-all@freebsd.org, Glen Barber X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 04 Oct 2014 03:11:10 -0000 --Apple-Mail=_7CDEB9E0-CF06-451B-971D-D7DC20EFC349 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=windows-1252 On Oct 2, 2014, at 16:34, Bruce Evans wrote: > There is still the larger problem with fts_read(). Applications like = rm > are specified to do a complete tree walk, with special handling for = files > that do not exist. If fts_read() is going to abort in the middle of a > tree walk, then it is unusable for implementing applications like rm. +1. In this case I was doing a du -sh /* while I was running rm -Rf /rel = (an old make release directory tree). This stopped the du -sh: $ sudo du -sh /* = = =20 8.0K /COPYRIGHT 996K /bin 218M /boot 0B /boot.config 2.5K /dev 4.0K /entropy 2.2M /etc 1.0G /home 16M /lib 280K /libexec 4.0K /media 4.0K /mnt 4.0K /proc du: /rel/usr/ports/net/samba36: No such file or directory du: /rel/usr/ports/net/aslookup: No such file or directory du: /rel/usr/ports/net/p5-Net-Amazon-AWSSign: No such file or directory du: /rel/usr/ports/net/p5-Net-Server-SS-PreFork: No such file or = directory du: /rel/usr/ports/net/lla: No such file or directory du: /rel/usr/ports/net/sslh: No such file or directory du: /rel/usr/ports/net/wmlj: No such file or directory du: /rel/usr/ports/net/sendsms: No such file or directory du: /rel/usr/ports/net/uriparser: No such file or directory du: /rel/usr/ports/net/p5-Data-IPV4-Range-Parse: No such file or = directory du: /rel/usr/ports/net/cagibi: No such file or directory du: /rel/usr/ports/net/fsplib: No such file or directory du: fts_read: No such file or directory The problem with changing fts_read to ignore ENOENT or other = errors will break compatibility with Linux [and other OSes potentially], = and is not the correct solution for this issue. I do however think that = the errnos to ignore with -f should be... - EACCES - ENOENT - EPERM =85 as filtering out these errors would handle the case that -f = should handle according to the manpage: -f Attempt to remove the files without prompting for = confirmation, regardless of the file's permissions. If the file does not exist, do not display a diagnostic message or modify the = exit status to reflect an error. The -f option overrides any = previous -i options. Thanks, -Garrett --Apple-Mail=_7CDEB9E0-CF06-451B-971D-D7DC20EFC349 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQEcBAEBCgAGBQJUL2VGAAoJEMZr5QU6S73ejPIH/1OaP9BHeJlVIwCwtzE9od2u yOMa8KH/4gzsYRQ15puBrZ2CDBIuwFbLmuAp1aaoiSCTf+EUqDCG4RT1+LcQ/d3D E+XHCqQ6RrgVuxyRohYcfFQk0bhvrc8sRkQaKBzRHCqk8TCHPoJydi9Ix7Ir2lem tPQOyq9fdUQlzN6dFdBMUAQCrwC0sN8Ozk0qxDeQnlMgD/w/paOemmQ3Bx4Yw7Pv 17C6ZsdccUtDwLB7yXtKLd7WMeJYUEtoqZKI4AEIIzBqyJdek0EBBxELoSFsL/bG 8RPvxEV4Pwi+CM/ItVjxnugwSMF/6s1vI89enoBJJgcUyEf1MXo1K2SylBQaoGU= =5ft1 -----END PGP SIGNATURE----- --Apple-Mail=_7CDEB9E0-CF06-451B-971D-D7DC20EFC349--