This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: setsockopt SO_REUSEADDR


> -----Original Message-----
> From: cygwin-owner On Behalf Of Rainer Hochreiter
> Sent: 05 October 2004 15:29

> running the program listed below with argument 'reuse' under 
> cygwin and linux returns different results!
> 
> from my point of view, the linux result is quite what i 
> expected, a bind() error 'Address already in use'. 

  Huh?  But that's exactly what SO_REUSEADDR is supposed to _prevent_ from
happening.  That's why it's called _REUSE_addr, because it lets you *re-use* an
addr, without getting an error message.  Why would you expect setting it to stop
you from reusing the address?

> why doen't bind() return an  error under cygwin?

  Because SO_REUSEADDR works _correctly_ on cygwin, perhaps?

    cheers, 
      DaveK
-- 
Can't think of a witty .sigline today....


--
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/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]