Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!cornell!biar!trebor From: trebor@biar.UUCP (Robert J Woodhead) Newsgroups: comp.unix.wizards Subject: Re: Dot files always first in directory? Message-ID: <535@biar.UUCP> Date: 5 May 89 04:09:46 GMT References: <11108@bloom-beacon.MIT.EDU> Reply-To: trebor@biar.UUCP (Robert J Woodhead) Organization: Biar Games, Inc. Lines: 18 In article <11108@bloom-beacon.MIT.EDU> jik@athena.mit.edu (Jonathan I. Kamens) writes: >It it safe to assume when writing a program which manipulates >directories that . and .. will always be the first two entries in a >directory? No. It isn't safe to make this assumption. Even if it is true on your machine, it may not be on another implementation (it isn't on my Xenix box, according to a quick test using ``l''), and it surely will be changed _just_to_smite_your_program_ at some time in the future. The only safe assumption to make when writing a program is that _everything_ and _everybody_ is out to get you. Variables won't; Constant's aren't; and Users like nothing more than to sadistically abuse your program. -- Robert J Woodhead, Biar Games, Inc. !uunet!biar!trebor | trebor@biar.UUCP "The lamb will lie down with the lion, but the lamb won't get much sleep." -- Woody Allen.