Path: utzoo!mnetor!tmsoft!torsqnt!news-server.csri.toronto.edu!bonnie.concordia.ca!uunet!spool.mu.edu!samsung!uakari.primate.wisc.edu!crdgw1!rpi!uupsi!sunic!liuida!indic.se!zap From: zap@indic.se (Jonas Petersson) Newsgroups: comp.sys.amiga.programmer Subject: ADCMD_ALLOCATE, ADIOF_NOWAIT => IOERR_ALLOCFAILED ? Summary: No, CapsLock is not jammed. Keywords: Audio channel allocation, PeekMsg() Message-ID: <1991Feb16.201228.524@indic.se> Date: 16 Feb 91 20:12:28 GMT Organization: Indic Computerised Air Quality Surveillance Lines: 29 I've just finished an Arexx sound daemon for those without lot's of chipmem (which might show up here in a while) and during that development I had some problems with the Audio device: No matter what parameters I put in the channel allocation request, the program either gets what it wants or hangs around 'til it does. ADIOF_NOWAIT, IOF_QUICK, low/illegal values for ln_Pri makes no difference, I have never got an IOERR_ALLOCFAILED... The simple solution is ofcourse to allocate no channels as the last combination, but I suppose I've missed something. Does someone have an example that produces an IOERR_ALLOCFAILED? Second question: Which is the "most civilized" way to check whether a msg is waiting at a port or not? I currently use: #define WaitingMsg(port) (port->mp_MsgList.lh_Head->ln_Type==NT_MESSAGE) Seems to work fine - any opinions? Jonas (My program was on Manx release disks, Yahoo! ;-) Petersson -- Absolut Software (Hack for fun) & Indic (Hacking for money) -- /// "Are you THE Zaphod Beeblebrox ????" # zap@indic.se __ /// # Air Quality Surveillance \\\/// "No, just A Zaphod Beeblebrox. # "I can feel it coming \/// Didn't you hear - I come in sixpacks !" # in the air..."