Path: utzoo!attcan!uunet!cbmvax!jesup From: jesup@cbmvax.UUCP (Randell Jesup) Newsgroups: comp.sys.amiga.tech Subject: Re: OpenDevice question Keywords: IORequest Message-ID: <5633@cbmvax.UUCP> Date: 5 Jan 89 19:42:58 GMT References: <3638@tekig5.PEN.TEK.COM> <5625@cbmvax.UUCP> <10687@umn-cs.CS.UMN.EDU> Reply-To: jesup@cbmvax.UUCP (Randell Jesup) Organization: Commodore Technology, West Chester, PA Lines: 23 In article <10687@umn-cs.CS.UMN.EDU> brant@uf.msc.umn.edu (Gary Brant) writes: >In article <5625@cbmvax.UUCP> jesup@cbmvax.UUCP (Randell Jesup) writes: >> NULL??!!! ALL IO requests must have the address of a valid port >>in the ReplyPort field. No exceptions. ... >> NULL is right out. ReplyMsg on a message with a null replyport will >>corrupt low memory, leading to a quick crash. > >This is very odd. I am looking at an example program in the RKM p.252 under >timer.device which explicitly sets the ReplyPort = NULL. I needed an >example for setting the system time/date [...] Anyway I have been running this >prog in my startup sequence to adjust the system date every boot. It >hasn't appeared to lead to any instability... or am i missing someting? Well, it so happens that example uses DoIO, and DoIO always tries quick IO. If quick IO is tried and succeeds, the replyport field isn't currently touched. If it fails, the replyport WILL be used. The example is broken, but happens to work ok in this particular case for the time being. There is NO guarantee that this is safe for any IO operation in any case. You'll note that the large timer example sets it up correctly. -- Randell Jesup, Commodore Engineering {uunet|rutgers|allegra}!cbmvax!jesup