]> CyberLeo.Net >> Repos - FreeBSD/stable/9.git/commit
MFC r237339:
authordelphij <delphij@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Wed, 27 Jun 2012 00:31:30 +0000 (00:31 +0000)
committerdelphij <delphij@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Wed, 27 Jun 2012 00:31:30 +0000 (00:31 +0000)
commit0e2a931aef0c612346c7904916c4d459f06df0e0
tree174531e1ff84f056c4909a026d576f22280778eb
parentb22ca91bfe6a5de4972ff238727381b62f1cefbf
MFC r237339:

Polish previous revision: if the fts_* routines have lstat()'ed the
directory entry then use the struct stat from that instead of doing
it again, and skip the rm_overwrite() call if fts_read() indicated
that the entry couldn't be a regular file.

Obtained from: OpenBSD

MFC r237284 (kevlo):

Fix potential symlink race condition in "rm -P" by adding a check
that the file we have opened is the one we expected.  Also open in
non-blocking mode to avoid a potential hang with FIFOs.

Obtained from: NetBSD via OpenBSD

git-svn-id: svn://svn.freebsd.org/base/stable/9@237615 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
bin/rm/rm.c