Path: utzoo!utgpu!news-server.csri.toronto.edu!rutgers!njin!njitgw!mars.njit.edu!gaines From: gaines@mars.njit.edu (Starman) Newsgroups: comp.unix.programmer Subject: How is the UNIX directory set up? Message-ID: <2265@njitgw.njit.edu> Date: 8 Feb 91 16:11:01 GMT Sender: news@njitgw.njit.edu Distribution: usa Organization: New Jersey Institute of Technology Lines: 29 Hi, I'm working on reading in the directory from the . file. I've broken up the structire so far as follows: Bytes 0-3 : file number Bytes 4-5 : File type Bytes 6-7 : filename length So far it's been working real well, except that at the end of one filename is the name of a file that's been deleted. The filename string is on a four word boundry and the 'extra' filestring is 5 chars long. I understand if there was an extra two or three bytes to make up for the 4word boundry, but why five characters? An exaple: alias.raycast0goofs00000 the zeros are '/0's. My first assumption was that filenames are on an eight word boundry rather than 4 word, but I have filenames 12 characters long total. The filename 'goofs' should not be in there. Also, there is one deleted file that has a four byte header rather than the eight byte (it has bytes 4-7) and other deleted files have the full eight byte headers. Any help? =========================================================================== "They can fly rings around the moon, | Mike but we're years ahead of them on the highway" | gaines@mars.njit.edu ===========================================================================