Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!ucbvax!decwrl!hplabs!hpfcdc!rml From: rml@hpfcdc.HP.COM (Bob Lenk) Newsgroups: comp.unix.wizards Subject: Re: Re: Dot files always first in directory? Message-ID: <5980048@hpfcdc.HP.COM> Date: 5 May 89 19:07:40 GMT References: <10210@smoke.BRL.MIL> Organization: HP Ft. Collins, Co. Lines: 14 In any file system implementation derived from any of the traditional AT&T or BSD systems, if the directory was created by mkdir(1) or mkdir(2) and nothing abnormal has occurred, the first two entries will be "." and "..". However, that includes a number of assumptions that reduce portability. There are other file system implementations. Even on traditional implementations it is possible for superusers to mknod(2) directories without "." and ".." or to unlink(2) these entries. It is easy enough to write code that tolerates but does not depend on seeing these entries anywhere in a directory (which is what POSIX requires for portable applications). Bob Lenk hplabs!hpfcla!rml rml%hpfcla@hplabs.hp.com