Path: utzoo!utgpu!news-server.csri.toronto.edu!bonnie.concordia.ca!uunet!munnari.oz.au!labtam!eyrie!walking!david From: david@walking.pub.uu.oz.au (David Le Blanc) Newsgroups: comp.sys.amiga.programmer Subject: Can you call DeviceProc() from a Task? Keywords: DeviceProc() dos.library dos process Message-ID: <6101@walking.pub.uu.oz.au> Date: 18 Jun 91 08:12:58 GMT Organization: Not an Organisation. Lines: 35 I would like to know if DeviceProc() and IoErr() can be called from a task? DeviceProc() does not seem to be like 'Read()' in that it does not use messages to accomplish its task. (Ie, it goes to the DOS list to find the process) How about IoErr()? Where does it find its Error code? I am pretty sure it goes to PROCESS->pr_Result2, in which case NO you can't use it in a task. Now, since DeviceProc returns a lock in IoErr(), does it need to be called from a Task? The reason I would like to know is: I am (pretending) to write a handler, which I am fairly certain is a DOS process (bit silly otherwise) however I understand the calling DOS from that context is BAD since while DOS is waiting on your pr_MsgPort for a reply to its 'Read()' or whatever, another process may just send you a message, which usually causes some sort of GURU (AsyncPkt usually). Now, are there some 'clean' things I can call? Like IoErr(), DeviceProc() etc? I am only worried because MOST dos calls can be done via a 'struct StandardPacket' with appropriate filler material, however DeviceProc() would require me to manually scan DOS Lists, which I would rather not do. (It is SUPPOSED to be a black box isnt it?) Cheers! David -- ----------------------------------------------------------------------------- David Le Blanc UUCP (home) : david@walking.pub.uu.oz.au david@walking ACSNET (work) : david@dogmelb.mlb.geomechanics.csiro.au - CSIRO Division of Geomechanics - Fragment analysis and 3D Fractal imaging - "What do you mean officer? This bike can't GO 140 km/h" -----------------------------------------------------------------------------