home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #26 / NN_1992_26.iso / spool / comp / protocol / tcpip / 5055 < prev    next >
Encoding:
Text File  |  1992-11-04  |  1.5 KB  |  39 lines

  1. Newsgroups: comp.protocols.tcp-ip
  2. Path: sparky!uunet!panther!panther3.panther.mot.com!ronf
  3. From: ronf@panther3.panther.mot.com (Ron Feigen)
  4. Subject: Re: TCP connect
  5. Message-ID: <1992Nov5.154116.5097@panther.mot.com>
  6. Sender: usenet@panther.mot.com
  7. Nntp-Posting-Host: panther3.panther.mot.com
  8. Organization: Motorola Panther Project, Chandler, AZ
  9. References: <Bx66Jn.D6@ushiva.wariat.org>
  10. Distribution: usa
  11. Date: Thu, 5 Nov 1992 15:41:16 GMT
  12. Lines: 25
  13.  
  14. In article <Bx66Jn.D6@ushiva.wariat.org> raw@ushiva.wariat.org (Roland Wilcher) writes:
  15. >
  16. >Some time ago there was a question about checking for a TCP connect
  17. >to a possibly non functioning machine without the long wait.
  18. >An answer was posted using connect with nonblocking mode. I don't
  19. >have that article now but would appreciate any pointers . Target
  20. >system would be Esix SVR4 using the socket libraries and TCP/IP.
  21. >
  22. >-- 
  23. >Lack of skill dictates economy of style.             raw@ushiva.ncoast.org
  24. >- Joey Ramone                                        raw@ushiva.wariat.org
  25. >Roland A. Wilcher                         6207 Luther Ave. Cleve Oh. 44103 
  26. >---------------------------------------------------------------------------
  27.  
  28. If the TCP socket is non-blocking the file descriptor will be ready for writing
  29. when the connection is complete.  There are several ways to check to see if the
  30. socket is ready for writing, select() is one of them.  Don't forget to check the
  31. errno after connect().  You are expecting EINPROGRESS, but you need to be
  32. prepared to handle other errors.
  33.  
  34. -- 
  35.  
  36. >
  37. Ron Feigen
  38. ronf@panther.mot.com
  39.