Dan McDonald writes: > On Thu, May 14, 2009 at 02:40:42PM -0400, James Carlson wrote: > <SNIP!> > > Yep. You could call it IP_PKTINFO. ;-} > > But does that take into account the local port?
Yes. The local port that you've bound will be used. > Or do I have to protect my local bound-to-port-500 socket with a mutex to > prevent multiple sending threads from stepping on each others' toes? That's exactly what this feature was designed to *avoid*. You can have a single socket bound to address INADDR_ANY and port 500, and use that one socket to send replies to clients, and use the proper source address (and port 500) on each. You no longer need to open up umpty-bazillion separate sockets and bind each one to a specific address. -- James Carlson, Solaris Networking <[email protected]> Sun Microsystems / 35 Network Drive 71.232W Vox +1 781 442 2084 MS UBUR02-212 / Burlington MA 01803-2757 42.496N Fax +1 781 442 1677 _______________________________________________ networking-discuss mailing list [email protected]
