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-11 06:21:31 +0400
committerChristopher Faylor <me@cgf.cx>2004-10-11 06:21:31 +0400
commit1cda132258b09d009064856dab1c36f3b9f19628 (patch)
treea2e4d9a212d2d6cd44aacbd9729df00dc6fe68b8 /winsup/cygwin/cygtls.h
parent8d712c8c3e7cdf417f60b9b38d87332c436114bd (diff)
* cygtls.h (exitsock): New element.
(exitsock_sin): Ditto. * cygtls.cc (_cygtls::init_thread): Initialize exitsock to invalid handle. (_cygtls::call2): Close exitsock if it is valid. * select.cc (struct socketinf): Remove sin element. (start_thread_socket): Initialize one SOCK_DGRAM socket per thread instead of (apparently) expensive opening and closing of socket with each select call. (socket_cleanup): Send a byte to the exitsock socket as a way to potentially signal a waiting-for-socket thread to exit. * tlsoffsets.h: Regenerate.
Diffstat (limited to 'winsup/cygwin/cygtls.h')
-rw-r--r--winsup/cygwin/cygtls.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/winsup/cygwin/cygtls.h b/winsup/cygwin/cygtls.h
index 2ce91dbc8..016bf8c9c 100644
--- a/winsup/cygwin/cygtls.h
+++ b/winsup/cygwin/cygtls.h
@@ -16,6 +16,8 @@ details. */
#define _NOMNTENT_FUNCS
#include <mntent.h>
#undef _NOMNTENT_FUNCS
+#define USE_SYS_TYPES_FD_SET
+#include <winsock.h>
#define CYGTLS_INITIALIZED 0x43227
#define CYGTLS_EXCEPTION (0x43227 + true)
@@ -61,6 +63,10 @@ struct _local_storage
char mnt_fsname[CYG_MAX_PATH];
char mnt_dir[CYG_MAX_PATH];
+ /* select.cc */
+ SOCKET exitsock;
+ struct sockaddr_in exitsock_sin;
+
/* strerror */
char strerror_buf[20];