Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!uunet!husc6!cmcl2!rutgers!columbia!cunixc!cck From: cck@cunixc.columbia.edu (Charlie C. Kim) Newsgroups: comp.sys.mac Subject: Re: How to write TEXT editors (part 1 of 2) Message-ID: <148@cunixc.columbia.edu> Date: Mon, 21-Sep-87 11:49:21 EDT Article-I.D.: cunixc.148 Posted: Mon Sep 21 11:49:21 1987 Date-Received: Wed, 23-Sep-87 06:43:45 EDT References: <3875@cisunx.UUCP> <20831@ucbvax.BERKELEY.EDU> <20860@ucbvax.BERKELEY.EDU> <20876@ucbvax.BERKELEY.EDU> Reply-To: cck@cunixc.columbia.edu (Charlie C. Kim) Organization: Columbia University Lines: 26 Keywords: System 4.1 and newer text edit On time interlocks: The AppleShare client (at least 1.1) is forced to use a "relative". What happens is that when it connects to the server it gets the time of day in a special format (based relative to Jan 1, 2001). References to time should be based upon this difference between this and the current Macintosh time on the client. Thus, unless the clock stops on a Macintosh, all macs on a network should have the same "relative" time in reference to a particular server. Also, time written, modified, etc. are usually written by the server. This is not to say the client cannot or willnot modify these times, but the above should alleviate the problems. I believe the preferable method to interlocking files is to use the "byte range lock" facility outlined in Inside Macintosh Volume 4. I would not depend on the AppleShare deny read/deny write, etc. open permissions. If you want to lock entire file, don't do what MacWrite does though: it locks 0x7fffffff bytes - there is a method for locking the entire file (I can't remember it happens if you specify 0 bytes or 0xffffffff bytes). Charlie C. Kim User Services Columbia University