freebsd-src/bin/rm
Glen Barber 9a87d320f3 MFC r268376 (imp):
rm -rf can fail sometimes with an error from fts_read. Make it
  honor fflag to ignore fts_read errors, but stop deleting from
  that directory because no further progress can be made.

  When building a kernel with a high -j value on a high core count
  machine, during the cleanobj phase we can wind up doing multiple
  rm -rf at the same time for modules that have subdirectories. This
  exposed this race (sometimes) as fts_read can return an error if
  the directory is removed by another rm -rf. Since the intent of
  the -f flag was to ignore errors, even if this was a bug in
  fts_read, we should ignore the error like we've been instructed
  to do.

Approved by:	re (kib)
Sponsored by:	The FreeBSD Foundation
2014-10-01 16:18:40 +00:00
..
Makefile Remove unnecessary SRCS= where could be guessed directly by our 2005-01-27 14:52:47 +00:00
rm.1 Add -x option to avoid crossing mount points when removing a hierarchy. 2013-04-26 17:45:37 +00:00
rm.c MFC r268376 (imp): 2014-10-01 16:18:40 +00:00