Where should the ".." file be ?

Doug Gwyn gwyn at smoke.BRL.MIL
Fri Mar 2 14:31:08 AEST 1990


In article <428 at marvin.jpl.oz> lm at marvin.jpl.oz (Luigi Martin) writes:
>I would like to know if the .. file HAS to be the second file entry in a 
>directory; or if the .. file can appear anywhere ( which means there is a bug
>in the depths of the find command ).

There need not even be any entries for "." and "..", although the
kernel still is obliged to understand their conventional meaning
when handling pathnames that contain these as pathname components.

Software that depends on "." or ".." being returned via readdir()
or equivalent directory scanning procedure is not very universal;
software that assumes that such entries are in particular slots
in a directory is really out on a limb.  It should be fixed.



More information about the Comp.unix.wizards mailing list