of the socket? Does doing a connect() call affect the receive

of the socket? Does doing a connect() call affect the receive


  From Richard Stevens (rstevens@noao.edu):

  Yes, in two ways.  First, only datagrams from your "connected peer"
  are returned.  All others arriving at your port are not delivered to
  you.

  But most importantly, a UDP socket must be connected to receive ICMP
  errors.  Pp. 748-749 of "TCP/IP Illustrated, Volume 2" give all the
  gory details on why this is so.



Home
FAQ