On 2/13/06, Andrew Pinski <[EMAIL PROTECTED]> wrote:
>
> On Feb 13, 2006, at 9:53 PM, Jason Crawford wrote:
>
> > On 2/13/06, Andrew Pinski <[EMAIL PROTECTED]> wrote:
> >> On Feb 13, 2006, at 9:24 PM, Damien Miller wrote:
> >>> Because that will fail when there are too many arguments, and will
> >>> probably break on filenames with spaces (use xargs -0 for these).
> >>
> >> Why not use -exec in find?
> >>
> >> find . -type f -name ttt -exec rm {}\;
> >
> > Because as stated many times on this list already (originally to
> > correct me), that will execute rm for each file, while piping to xargs
> > will only run rm once xargs stops getting input, or when it hits max
> > command line length, in which case it will execute another rm based on
> > input from the pipe.
>
> Time to write your own program in C instead if the time to invoke
> rm is taking too much time.

No point, xargs does what I need it to do, and is much more efficient
than having find execute rm itself. The fewer times you call execve(2)
the better.

Jason

Reply via email to