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: 1.5.9-1: socket() appears NOT to be thread-safe

On Thu, 10 Jun 2004, Brian Ford wrote:

> I put a call to try_to_debug in find_winsock_errno when it returned the
> default EPERM.  Then, by setting
> CYGWIN="error_start=c:\cygwin\bin\gdb.exe" I can get a gdb pop up and do a
> back trace.  The error was:
> 10093
> Either the application has not called WSAStartup, or WSAStartup failed.
> and came from the socket call in cygwin_socket.
> So, given this is some sort of race condition, how do I debug the autoload
> code and find out if WSAStartup was actually called or if it failed?

Ok, I put another try_to_debug call in wsock_init just inside the if
(!wsock_started).  Sometimes I hit it first and the socket call succeeds.
But, sometimes I hit the one above first and the socket call fails.  In
the later case, wsock_started=1.  Any idea how that could happen?

Brian Ford
Senior Realtime Software Engineer
VITAL - Visual Simulation Systems
FlightSafety International
the best safety device in any aircraft is a well-trained pilot...

Unsubscribe info:
Problem reports:

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