Path: utzoo!mnetor!uunet!husc6!necntc!dandelion!ulowell!page From: page@ulowell.cs.ulowell.edu (Bob Page) Newsgroups: comp.sys.amiga Subject: Re: File System suggestions Message-ID: <2106@ulowell.cs.ulowell.edu> Date: 11 Dec 87 18:02:57 GMT References: <2086@ulowell.cs.ulowell.edu> <1228@sugar.UUCP> Reply-To: page@swan.ulowell.edu (Bob Page) Organization: University of Lowell, Computer Science Dept. Lines: 39 peter@sugar.UUCP (Peter da Silva) wrote: >Why do you need [file truncation]? Not a flame, a request for info. For example, the CHOP utility would use it, for hacking off the extra bytes from an XMODEM transfer. Essentially Truncate() can be done by copying the file (except for the last n bytes) to a new file and deleting the original, but that takes lots of time and space. Re: file links, I have it from a reliable source that the newFS from CBM has file links in it, and they do it a different way than the two methods I described. I don't know enough about the method, but it looks like they create a block with a LINK type flag and have two pointers (front and back), thus creating a doubly-linked list of file headers; the head (?) containing all the traditional info (size, block list, modification date, etc). If this is true, deleting a link is easy, and deleting the head just means Rename() the head and delete the tail (or some other node in the list, I don't know the details). However, it means you have to modify DOS to always traverse the list when you need to know anything in the file besides its name, unless you keep all the information about the file header in each link block - in which case you're just cloning file headers, like method #2 I described in my original article. I'd like to know more about this - from the description I got it seems potentially time-consuming (potentially n seeks for a file with n links). And I'd like to know if it works with directory blocks. I'd rather see those forward and back pointers used for something else, like a 'creation date' or some such (note the current implementation uses the date fields for 'last modified date'). ..Bob -- Bob Page, U of Lowell CS Dept. page@ulowell.edu ulowell!page "I've never liked reality all that much, but I haven't found a better solution." --Dave Haynie, Commodore-Amiga