On Tue, 09 Jun 2009 12:05:05 +0200, Joerg Schilling wrote:

> > > qfile --orphans $(find -H /usr/lib /lib -type f)
> > > 
> > > which avoids checking all the symlinks.  
> 
> In case that you find implementation works correctly, this will
> not change anything unless either /usr/lib or /lib are symlinks.
> 
> If you however use find -L, -type f will find even all symlinks in case
> they are pointing to a file.

The idea is not have find NOT follow symlinks, except when the given path
is a symlink (which it often is on a 64 bit machine).

Checking the symlinks is a waste of time, it's faster to remove only real
files that are orphaned, then remove any dangling symlinks after.
Otherwise qfile has to check about three times as many objects.


-- 
Neil Bothwick

Handy Guide to Modern Science:
   1. If it's green or it wiggles, it's biology.
   2. If it stinks, it's chemistry.
   3. If it doesn't work, it's physics.

Attachment: signature.asc
Description: PGP signature

Reply via email to