On Thu, 17 Aug 2006, Corinna Vinschen wrote: > On Aug 17 09:06, Brian Ford wrote: > > Oh yeah, you must call the setsockopt below after the bind on windows. > > Search MSDN for why. > > P.S.: Do you know the MSDN articel off-hand, maybe?
http://support.microsoft.com/default.aspx?scid=kb;en-us;131978 Excerpt: For example: #define RECV_IP_ADDR "225.6.7.8" // arbitrary multicast address mreq.imr_multiaddr.s_addr = inet_addr(RECV_IP_ADDR); mreq.imr_interface.s_addr = INADDR_ANY; err = setsockopt(sock, IPPROTO_IP, IP_ADD_MEMBERSHIP, (char*)&mreq, sizeof(mreq)) Note that it is necessary to bind to an address before calling the setsockopt() function. -- Brian Ford Lead Realtime Software Engineer VITAL - Visual Simulation Systems FlightSafety International the best safety device in any aircraft is a well-trained crew... . -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/