[PATCH] interruptable accept

Thomas Pfaff tpfaff@gmx.net
Mon Jul 1 04:12:00 GMT 2002


This patch is not 100% perfect and could be done better (faster response
on incoming signal) with async Events but this would require a much larger
patch (Call AsyncEventSelect, WaitForMultipleObjects (socket and signal),
check for pending connection and set socket back to blocking mode).
Therefore i decided to use select and check for signal every 100ms. IMHO a
max of 100 ms delay for a pending signal is acceptable here and is at
least better than the current implementation.

Thomas

Changelog

2002-07-01  Thomas Pfaff  <tpfaff@gmx.net>

	*net.cc: Include select.h
	(cygwin_accept): If socket is nonblocking check for a pending
	signal every 100ms.
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: accept_intr.patch
URL: <http://cygwin.com/pipermail/cygwin-patches/attachments/20020701/4c00ea53/attachment.ksh>


More information about the Cygwin-patches mailing list