Next: Problems with dead NFS servers, Previous: Systems without O_NOFOLLOW, Up: Changing the Current Working Directory
Where an automounter is in use on systems that do not support
O_FOLLOW, it can be the case that the use of the chdir()
system
call can itself cause a new filesystem to be mounted at that point.
This will cause find
's security check to fail. However, this
does not normally represent a security problem (since the automounter
configuration is normally set up by the system administrator).
Therefore, if the chdir()
sanity check fails, find
will
check to see if a new filesystem has been mounted at the current
directory; if so, find
will issue a warning message and
continue.
To make this solution work, find
reads the list of mounted
filesystems at startup, and again when the sanity check fails. It
compares the two lists to find out if the directory it has moved into
has just been mounted.