🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.sys.amiga.tech
Article #10828

Re: OpenDevice question

#10828
From: Randell Jesup
Date: Thu, 05 Jan 1989 19:42
23 lines
1721 bytes
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
Technical Details
Message-ID: <5633@cbmvax.UUCP>
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!cbmvax!jesup
References: <3638@tekig5.PEN.TEK.COM> <5625@cbmvax.UUCP> <10687@umn-cs.CS.UMN.EDU>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!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