Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristopher Faylor <me@cgf.cx>2004-10-20 05:02:18 +0400
committerChristopher Faylor <me@cgf.cx>2004-10-20 05:02:18 +0400
commitf054a20f1ab3cedd4eed61c227e3b90bad96c93d (patch)
tree4d52bbc8fdb91e015ee519c7b7967c30bd86efaf /winsup/cygwin/select.cc
parentf9dcc467ccff78d5de67fb6c2582731424e8da82 (diff)
* fhandler_console.cc (fhandler_console::fixup_after_exec): Fix error message.
Diffstat (limited to 'winsup/cygwin/select.cc')
-rw-r--r--winsup/cygwin/select.cc11
1 files changed, 7 insertions, 4 deletions
diff --git a/winsup/cygwin/select.cc b/winsup/cygwin/select.cc
index b85e0bd56..ffddf6204 100644
--- a/winsup/cygwin/select.cc
+++ b/winsup/cygwin/select.cc
@@ -1347,10 +1347,13 @@ start_thread_socket (select_record *me, select_stuff *stuff)
if (_my_tls.locals.exitsock != INVALID_SOCKET)
{
- char buf[1];
- si->exitsock = _my_tls.locals.exitsock;
- select_printf ("read a byte from %p", si->exitsock);
- recv (si->exitsock, buf, 1, 0);
+ if (!si->exitsock)
+ {
+ char buf[1];
+ si->exitsock = _my_tls.locals.exitsock;
+ select_printf ("read a byte from %p", si->exitsock);
+ recv (si->exitsock, buf, 1, 0);
+ }
}
else
{