Path: utzoo!mnetor!uunet!husc6!bbn!uwmcsd1!leah!itsgw!imagine!pawl23.pawl.rpi.edu!jesup From: jesup@pawl23.pawl.rpi.edu (Randell E. Jesup) Newsgroups: comp.sys.amiga Subject: Re: a very simple question on DoIO/GetMsg/device drivers Message-ID: <180@imagine.PAWL.RPI.EDU> Date: 24 Dec 87 08:01:20 GMT References: <890@louie.udel.EDU> Sender: news@imagine.PAWL.RPI.EDU Reply-To: beowulf!lunge!jesup@steinmetz.UUCP Distribution: na Organization: RPI Public Access Workstation Lab - Troy, NY Lines: 30 In article <890@louie.udel.EDU> rminnich@udel.EDU (Ron Minnich) writes: >I have a very simple question and i think a very simple problem >involving internet.device. Here is the scenario: ... > Telnet gets the news. It does a CheckIO(Request), which returns >non-zero value. It also does a WaitIO for grins, and gets a zero >back. Then the fun begins. The port in this case is called tcpinp. >If i look at tcpinp->MsgList (not the exact name), the lh_Head >points to Request, and lh_TailPred points to Request. But a >GetMsg(tcpinp) returns a 0! How can this happen? Note: while it is not mentioned in the autodocs (people at C/A also might want to note for the next autodocs), WaitIO removes the message from the port, no GetMsg needed (it'll return 0 always). Beyond that, it sounds like many errors I've had: They seem absolutely incomprehensible, to the point of blaming compilers/OS/whatever, until you walk through it or tweak it for the nth time and the light suddenly dawns. A first step: dump the GetMsg and CheckIO, just WaitIO (if you don't mind waiting, and know it'll be sent back.) Next step, if it still doesn't work, triple-check everything, make sure you're not playing with it anywhere you shouldn't, snapshot the list before and after the WaitIO (Note: the message will still have pointers to the list in it). If it still doesn't work, look at any code that uses messages you can find (like vt100 x.x). >ron (rminnich@udel.edu) // Randell Jesup Lunge Software Development // Dedicated Amiga Programmer 13 Frear Ave, Troy, NY 12180 \\// lunge!jesup@beowulf.UUCP (518) 272-2942 \/ (uunet!steinmetz!beowulf!lunge!jesup)