On Fri, Apr 26, 2013 at 08:33:54AM -0500, Joshua Isom wrote: > On 4/26/2013 7:23 AM, Eitan Adler wrote: > > Yes, rm's functionality can be fully replicated by find.
> As well as anything using -R. Emulating other -R things using find becomes quite slow when you don't want to impose {PATH_MAX} limits or open up symlink-based race windows because the only safe option is -execdir UTILITY {} \;. Any find command based on -exec, -print or -print0 passes pathnames which are subject to {PATH_MAX} limits and directories concurrently replaced with symlinks. The construct -execdir ... {} + is unusably broken in older FreeBSD versions and gives no advantage compared to -execdir ... {} \; in recent -CURRENT. With -L, this is not a new problem because symlinks are followed anyway and the underlying code (fts(3)) always imposes the {PATH_MAX} limit in that case. The -delete primary is safe like -execdir. I'm not entirely sure about this because the rm(1) patch is simple and the new syntax is fairly clear. -- Jilles Tjoelker _______________________________________________ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "freebsd-hackers-unsubscr...@freebsd.org"