diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2022-09-08 14:18:10 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2022-09-08 14:18:10 (GMT) |
commit | c0ad0edfe03a4a4119f22763f04cae0bf8f94282 (patch) | |
tree | 035d67b22eb527608cbd45d864d394b89064412a /win/tclWinSock.c | |
parent | c603f00cf1e79360cab83bed72e551df8b19fe56 (diff) | |
parent | 607e3a5ba3c721c845b29c89db243882f25c5ba5 (diff) | |
download | tcl-c0ad0edfe03a4a4119f22763f04cae0bf8f94282.zip tcl-c0ad0edfe03a4a4119f22763f04cae0bf8f94282.tar.gz tcl-c0ad0edfe03a4a4119f22763f04cae0bf8f94282.tar.bz2 |
Merge 8.7
Diffstat (limited to 'win/tclWinSock.c')
-rw-r--r-- | win/tclWinSock.c | 15 |
1 files changed, 4 insertions, 11 deletions
diff --git a/win/tclWinSock.c b/win/tclWinSock.c index 610081a..8d16b5c 100644 --- a/win/tclWinSock.c +++ b/win/tclWinSock.c @@ -118,9 +118,9 @@ typedef struct TcpFdList { struct TcpState { Tcl_Channel channel; /* Channel associated with this socket. */ - struct TcpFdList *sockets; /* Windows SOCKET handle. */ int flags; /* Bit field comprised of the flags described * below. */ + struct TcpFdList *sockets; /* Windows SOCKET handle. */ int watchEvents; /* OR'ed combination of FD_READ, FD_WRITE, * FD_CLOSE, FD_ACCEPT and FD_CONNECT that * indicate which events are interesting. */ @@ -158,8 +158,6 @@ struct TcpState { * Access must be protected by semaphore */ struct TcpState *nextPtr; /* The next socket on the per-thread socket * list. */ - int testFlags; /* bit field for tests. Is set by testsocket - * test procedure */ }; /* @@ -179,12 +177,7 @@ struct TcpState { * still pending */ #define TCP_ASYNC_FAILED (1<<5) /* An async connect finally failed */ -/* - * These bits may be ORed together into the "testFlags" field of a TcpState - * structure. - */ - -#define TCP_ASYNC_TEST_MODE (1<<0) /* Async testing activated. Do not +#define TCP_ASYNC_TEST_MODE (1<<8) /* Async testing activated. Do not * automatically continue connection * process */ @@ -623,7 +616,7 @@ WaitForConnect( * - Call by the event queue (errorCodePtr == NULL) */ - if (GOT_BITS(statePtr->testFlags, TCP_ASYNC_TEST_MODE) + if (GOT_BITS(statePtr->flags, TCP_ASYNC_TEST_MODE) && errorCodePtr != NULL && GOT_BITS(statePtr->flags, TCP_NONBLOCKING)) { *errorCodePtr = EWOULDBLOCK; @@ -1310,7 +1303,7 @@ TcpGetOptionProc( * below. */ - if (!GOT_BITS(statePtr->testFlags, TCP_ASYNC_TEST_MODE)) { + if (!GOT_BITS(statePtr->flags, TCP_ASYNC_TEST_MODE)) { WaitForConnect(statePtr, NULL); } |