mirror of
git://sourceware.org/git/newlib-cygwin.git
synced 2025-01-18 12:29:32 +08:00
* select.cc (cygwin_select): Remove select_timeout test.
(select_stuff::wait): Return select_set_zero on timeout. (thread_socket): Report timeout when debugging.
This commit is contained in:
parent
3791ab4cd5
commit
abf1b60039
@ -1,3 +1,9 @@
|
||||
2012-06-09 Christopher Faylor <me.cygwin2012@cgf.cx>
|
||||
|
||||
* select.cc (cygwin_select): Remove select_timeout test.
|
||||
(select_stuff::wait): Return select_set_zero on timeout.
|
||||
(thread_socket): Report timeout when debugging.
|
||||
|
||||
2012-06-05 Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
|
||||
|
||||
* include/elf.h: Update from FreeBSD.
|
||||
|
@ -168,9 +168,7 @@ cygwin_select (int maxfds, fd_set *readfds, fd_set *writefds, fd_set *exceptfds,
|
||||
else
|
||||
res = sel.wait (r, w, e, ms); /* wait for an fd to become
|
||||
become active or time out */
|
||||
if (res == select_stuff::select_timeout)
|
||||
res = 0; /* No fd's were active. */
|
||||
else if (res >= 0)
|
||||
if (res >= 0)
|
||||
{
|
||||
copyfd_set (readfds, r, maxfds);
|
||||
copyfd_set (writefds, w, maxfds);
|
||||
@ -383,7 +381,7 @@ next_while:;
|
||||
break;
|
||||
case WAIT_TIMEOUT:
|
||||
select_printf ("timed out");
|
||||
res = select_timeout;
|
||||
res = select_set_zero;
|
||||
break;
|
||||
case WAIT_OBJECT_0 + 1:
|
||||
if (startfds > 1)
|
||||
@ -1305,7 +1303,7 @@ thread_socket (void *arg)
|
||||
/ MAXIMUM_WAIT_OBJECTS));
|
||||
bool event = false;
|
||||
|
||||
select_printf ("stuff_start %p", si->start);
|
||||
select_printf ("stuff_start %p, timeout %u", si->start, timeout);
|
||||
while (!event)
|
||||
{
|
||||
for (select_record *s = si->start; (s = s->next); )
|
||||
|
@ -71,7 +71,6 @@ class select_stuff
|
||||
public:
|
||||
enum wait_states
|
||||
{
|
||||
select_timeout = -4,
|
||||
select_signalled = -3,
|
||||
select_loop = -2,
|
||||
select_error = -1,
|
||||
|
Loading…
x
Reference in New Issue
Block a user