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] |
I'm trying to test some socket code inside a single process. I have two threads, a server and a client, and try to connect a Unix domain socket between them, but the threads block on accept() and connect() respectively. I've tried blocking on select() so that the accept() does not block, with the same results. When the server and client are forked into different processes, the connection works fine. This problem seems similar to that reported in http://cygwin.com/ml/cygwin-developers/2003-02/msg00064.html except that my sockets are Unix domain, so my connecting socket should be looking in the right place. However, that thread is pretty old, and I'm running a more recent version of Cygwin. The problem is also possibly related to http://www.nntp.perl.org/group/perl.ithreads/2007/01/msg1142.html Although I don't know any perl, so maybe not. My guess is accept() and connect() share some process scope internal lock. As a sanity check, I've attached a successful run on Ubuntu. I've also attached the output from $ cygcheck -s -v -r > cygcheck.out Thanks for your time, Trevor King
Attachment:
cygwin_run.txt
Description: Text document
Attachment:
ubuntu_run.txt
Description: Text document
Attachment:
check_cs2.c
Description: Binary data
Attachment:
cygcheck.out
Description: Binary data
-- 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] |