Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 485d8c22a7a80b279ba31dcdb05e1c48e26e1bdbf10d10dccc429bb3971f61d5
Ticket: 0be26484a0743c05cb7e04c8d4caf62bbc6a99c3
mutex in TclpFinalizeNotifier in the epoll and kqueue notifiers
User & Date: anonymous on 2026-05-25 14:06:55
Changes

  1. assignee changed to: "nobody"
  2. closer changed to: "nobody"
  3. cmimetype changed to: "text/x-markdown"
  4. comment changed to:
    The notifier in `unix/tclEpollNotfy.c` has a `notifierMutex` in its `ThreadSpecificData`. The comment says that this mutex protects notifier termination in `TclpFinalizeNotifier`. In `TclpFinalizeNotifier`, indeed the code is protected by
    ```
        pthread_mutex_lock(&tsdPtr->notifierMutex);
        ...
        pthread_mutex_unlock(&tsdPtr->notifierMutex);
    ```
    
    However, since `notifierMutex` is not acquired in `TclpAlertNotifier` or anywhere else (if `NOTIFIER_EPOLL` is defined), the mutex does not seem to be doing anything useful. This may be a vestige of the select-based notifier, which does acquire `notifierMutex` in `TclpAlertNotifier`.
    
    The same issue occurs in the kqueue notifier.
    
  5. foundin changed to: "Tcl 9.1a2"
  6. is_private changed to: "0"
  7. login: "anonymous"
  8. priority changed to: "5 Medium"
  9. resolution changed to: "None"
  10. severity changed to: "Important"
  11. status changed to: "Open"
  12. submitter changed to: "anonymous"
  13. subsystem changed to: "02. Event Loops"
  14. title changed to:
    mutex in TclpFinalizeNotifier in the epoll and kqueue notifiers
    
  15. type changed to: "Bug"