This is the mail archive of the cygwin@cygwin.com 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: connect() not interrupted by sigalrm?


Dear Elfyn,

Thanks for your prompt response:

> Cockpit error. You left out a few headers.
> - string.h is needed for memset()
> - unistd.h is needed for alarm()
> - arpa/inet.h is needed for inet_addr()
> 
> After that it works fine.

The addition of these include files does make gcc -Wall happier, but
it not change the behavior of the program at run-time. Under Cygwin on
my XP box, it still waits many seconds for the connect() to timeout
and then returns with a "Connection timed out" error, instead of
returning after the 2 second alarm with the desired "Interrupted
system call" error.

Eric



--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.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]