home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #31 / NN_1992_31.iso / spool / comp / sys / amiga / programm / 18049 < prev    next >
Encoding:
Internet Message Format  |  1993-01-02  |  1.5 KB

  1. Path: sparky!uunet!gatech!concert!uvaarpa!adastra!mbs
  2. From: mbs@adastra.cvl.va.us (Michael B. Smith)
  3. Newsgroups: comp.sys.amiga.programmer
  4. Subject: Re: RKM description of WaitPort()
  5. Distribution: world
  6. Message-ID: <mbs.1iv3@adastra.cvl.va.us>
  7. References:  <1993Jan1.221013.26070@urbana.mcd.mot.com>
  8. X-NewsSoftware: GRn-beta 1.16g (01.01.93) by Michael B. Smith & Mike Schwartz
  9. MIME-Version: 1.0
  10. Content-Type: text/plain; charset=iso-8859-1
  11. Content-Transfer-Encoding: 8bit
  12. Date: 2 Jan 93 09:44:52 EST
  13. Organization: Well, I haven't decided on a name yet...
  14. Lines: 19
  15.  
  16. In article <1993Jan1.221013.26070@urbana.mcd.mot.com> qbarnes@urbana.mcd.mot.com (Quentin Barnes) writes:
  17. > I was reading the description of the WaitPort() call in the RKM:Libraries
  18. > and was confused by the description.  On page 504, it says:
  19. >
  20. >       ...  It is possible to receive a signal for a port without
  21. >       a message being present yet.  The code processing the
  22. >       messages should be able to handle this. ...
  23. >
  24. > It seems to me to OS is waking up the task before it has attached the
  25. > message to the specified port and it would be up the the application
  26. > to spin on the GetMsg() call until the message generating the signal
  27. > showed up.  This seems terribly wrong and the example code does not
  28.  
  29. The word "yet" should be deleted. Do NOT spin on GetMsg(). Instead,
  30. gracefully handle the situation where GetMsg() == NULL, which *is* done
  31. by the example on page 505 under "Getting a Message".
  32. --
  33.   //   Michael B. Smith
  34. \X/    mbs@adastra.cvl.va.us  -or-  uunet.uu.net!virginia.edu!adastra!mbs
  35.