On Thu, Aug 23, 2012 at 12:32 PM, Jan Stary <[email protected]> wrote: > cp.c says: > > /* > * mastercmp -- > * The comparison function for the copy order. The order is to copy > * non-directory files before directory files. The reason for this > * is because files tend to be in the same cylinder group as their > * parent directory, whereas directories tend not to be. Copying the > * files first reduces seeking. > */ ... > Doesn't the code actually do the opposite? > If 'a' is a directory, it comes first?
Yep. Nice catch. > Should that be FTS_F? I think it's correct to do the test against FTS_D, it just should return them in the other direction to do what the comment says. What I don't know is whether the rule described is actually still considered a good and useful thing still. Otto? Philip Guenther
