Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 8b5228012ae8e432f3f3bea0ccc092824d7722c583e138cc0cab8cf22a9b7a37
Ticket: 0b809cd3fc8b6e5e19cd8a9a91357e425472cd69
SIGSEGV on shutdown with TclOO, coroutines, namespaces, and -DPURIFY
User & Date: sebres on 2024-12-04 13:01:46
Changes

  1. icomment:
    I can reproduce it with 8.6+ without any trace...
    
    
    ```
    Thread 1 received signal SIGSEGV, Segmentation fault.
    0x00007ffd56430aa6 in TclOOObjectName (interp=0xda8270, oPtr=0xfeeefeeefeeefeee) at ./generic/tclOO.c:2937
    2937        if (oPtr->cachedNameObj) {
    (gdb) where
    #0  0x00007ffd56430aa6 in TclOOObjectName (interp=0xda8270, oPtr=0xfeeefeeefeeefeee) at ./generic/tclOO.c:2937
    #1  0x00007ffd56440e78 in MethodErrorHandler (interp=0xda8270, methodNameObj=0x25dd990) at ./generic/tclOOMethod.c:1162
    #2  0x00007ffd564592c9 in InterpProcNR2 (data=0x2633168, interp=0xda8270, result=1) at ./generic/tclProc.c:1874
    #3  0x00007ffd562ffb65 in TclNRRunCallbacks (interp=0xda8270, result=1, rootPtr=0x2648e40) at ./generic/tclBasic.c:4541
    #4  0x00007ffd56306494 in DeleteCoroutine (clientData=0x2646b20) at ./generic/tclBasic.c:8743
    ```
    
    mPtr->declaringClassPtr shows indeed deleted object... The reason for that is, there is no cross reference between methods and instances (probably to avoid cyclic refs), and the instance doesn't get reset if class or object gets deleted in case of the method remains due to its ref-counter, neither in TclOODelMethodRef (nor in its caller).
    
    I've already fixed it, it's coming soon.
    
  2. login: "sebres"
  3. mimetype: "text/x-markdown"