Eliminate trailing whitespace in some files.

* dll_init.cc (dll_list::alloc): Reset 'p' in forked process.
* select.cc (select_stuff::wait): Move cleanup() closer to WFMO to minimize
unavoidable (?) race.
This commit is contained in:
Christopher Faylor 2011-05-02 15:28:35 +00:00
parent 138f3e0cbd
commit 8978381c2a
8 changed files with 28 additions and 13 deletions

View File

@ -1,3 +1,10 @@
2011-05-02 Christopher Faylor <me.cygwin2011@cgf.cx>
* dll_init.cc (dll_list::alloc): Reset 'p' in forked process.
* select.cc (select_stuff::wait): Move cleanup() closer to WFMO to
minimize unavoidable (?) race.
2011-05-02 Corinna Vinschen <corinna@vinschen.de>
* fhandler_serial.cc (fhandler_serial::raw_read): Add restartability

View File

@ -126,6 +126,7 @@ dll_list::alloc (HINSTANCE h, per_process *p, dll_type type)
{
if (!in_forkee)
d->count++; /* Yes. Bump the usage count. */
d->p = p;
}
else
{

View File

@ -1,4 +1,4 @@
/* pseudo-reloc.c
/* pseudo-reloc.cc
Contributed by Egor Duda <deo@logos-m.ru>
Modified by addition of runtime_pseudo_reloc version 2

View File

@ -146,7 +146,6 @@ cygwin_select (int maxfds, fd_set *readfds, fd_set *writefds, fd_set *exceptfds,
else if ((timeout = sel.wait (r, w, e, ms) < 0))
return -1; /* some kind of error */
sel.cleanup ();
copyfd_set (readfds, r, maxfds);
copyfd_set (writefds, w, maxfds);
copyfd_set (exceptfds, e, maxfds);
@ -301,15 +300,18 @@ select_stuff::wait (fd_set *readfds, fd_set *writefds, fd_set *exceptfds,
switch (wait_ret)
{
case WAIT_OBJECT_0:
cleanup ();
select_printf ("signal received");
set_sig_errno (EINTR);
return -1;
case WAIT_FAILED:
cleanup ();
system_printf ("WaitForMultipleObjects failed");
s = &start;
s->set_select_errno ();
return -1;
case WAIT_TIMEOUT:
cleanup ();
select_printf ("timed out");
res = 1;
goto out;
@ -325,6 +327,7 @@ select_stuff::wait (fd_set *readfds, fd_set *writefds, fd_set *exceptfds,
while ((s = s->next))
if (s->saw_error ())
{
cleanup ();
set_errno (s->saw_error ());
return -1; /* Somebody detected an error */
}
@ -334,7 +337,10 @@ select_stuff::wait (fd_set *readfds, fd_set *writefds, fd_set *exceptfds,
select_printf ("gotone %d", gotone);
if (gotone)
goto out;
{
cleanup ();
goto out;
}
if (ms == INFINITE)
{
@ -346,6 +352,7 @@ select_stuff::wait (fd_set *readfds, fd_set *writefds, fd_set *exceptfds,
LONGLONG now = gtod.msecs ();
if (now > (start_time + ms))
{
cleanup ();
select_printf ("timed out after verification");
goto out;
}