Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 16cc22e5ddaead951340fc328160bae43955078c
Ticket: 849007ffffffffffffffffffffffffffffffffff
bug in Tcl_ConditionNotify for win build
User & Date: nobody on 2003-11-25 15:03:36
Changes

  1. assignee changed to: "andreas_kupries"
  2. cmimetype changed to: "text/plain"
  3. comment changed to:
    in the first if, need the '*' !! (ie. *condPtr)
    the following code, is after the fix.
    
    void
    Tcl_ConditionNotify(condPtr)
        Tcl_Condition *condPtr;
    {
        WinCondition *winCondPtr;
        ThreadSpecificData *tsdPtr;
        if (*condPtr != NULL) {
    winCondPtr = *((WinCondition **)condPtr);
    
    /*
     * Loop through all the threads waiting on the 
    condition
     * and notify them (i.e., broadcast 
    semantics).  The queue
     * manipulation is guarded by the per-
    condition coordinating mutex.
     */
    
    EnterCriticalSection(&winCondPtr->condLock);
    while (winCondPtr->firstPtr != NULL) {
        tsdPtr = winCondPtr->firstPtr;
        winCondPtr->firstPtr = tsdPtr->nextPtr;
        if (winCondPtr->lastPtr == tsdPtr) {
    winCondPtr->lastPtr = NULL;
        }
        tsdPtr->flags = WIN_THREAD_RUNNING;
        tsdPtr->nextPtr = NULL;
        tsdPtr->prevPtr = NULL;/* Not strictly 
    necessary, see A: */
        SetEvent(tsdPtr->condEvent);
    }
    LeaveCriticalSection(&winCondPtr->condLock);
        } else {
    /*
     * Noone has used the condition variable, so 
    there are no waiters.
     */
        }
    }
    
    
  4. foundin changed to: "obsolete: 8.4.5"
  5. priority changed to: "5 Medium"
  6. resolution changed to: "None"
  7. status changed to: "Open"
  8. submitter changed to: "nobody"
  9. subsystem changed to: "49. Threading"
  10. title changed to: "bug in Tcl_ConditionNotify for win build"
  11. type changed to: "Bug"