Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 699cc6d2d7237fa91c041d8e216ffe6dca8a77c7
Ticket: 410674ffffffffffffffffffffffffffffffffff
Bug fix: #219205 and 219333 (event drop)
User & Date: hobbs on 2001-03-31 07:39:06
Changes

  1. closedate changed to: "2001-03-31T00:39:06"
  2. closer changed to: "hobbs"
  3. icomment:
    Logged In: YES 
    user_id=72656
    
    After some back and forth discussion, it was decided to go 
    with:
    
    diff -b -c -r1.19 tclWinSock.c
    *** win/tclWinSock.c    2000/09/28 06:38:23     1.19
    --- win/tclWinSock.c    2001/03/31 00:27:25
    ***************
    *** 836,844 ****
            if ((*winSock.select)(0, &readFds, NULL, NULL, 
    &timeout) != 0) {
                mask |= TCL_READABLE;
            } else {
                SendMessage(tsdPtr->hwnd, SOCKET_SELECT,
                        (WPARAM) SELECT, (LPARAM) infoPtr);
    -           infoPtr->readyEvents &= ~(FD_READ);
            }
          }
          if (events & (FD_WRITE | FD_CONNECT)) {
    --- 836,844 ----
            if ((*winSock.select)(0, &readFds, NULL, NULL, 
    &timeout) != 0) {
                mask |= TCL_READABLE;
            } else {
    +           infoPtr->readyEvents &= ~(FD_READ);
                SendMessage(tsdPtr->hwnd, SOCKET_SELECT,
                        (WPARAM) SELECT, (LPARAM) infoPtr);
            }
          }
          if (events & (FD_WRITE | FD_CONNECT)) {
    
    
    This just moves the infoPtr flag correction before the 
    SendMessage.  It appears we were hitting a rare race 
    condition that could cause the hang, where the recipient of 
    the SendMessage received the message before the infoPtr 
    flags could be corrected.  This was tested again from 8.2-
    8.4a2.  In 8.4a2cvs.
    
    
  4. login: "hobbs"
  5. mimetype: "text/plain"
  6. resolution changed to: "Fixed"
  7. status changed to: "Closed"
  8. username: "hobbs"