Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: a7edba0b72bcac4ab08b4be92b27fb4a7bcc48c0
Ticket: 1705778fffffffffffffffffffffffffffffffff
valgrind error reports
User & Date: andreas_kupries on 2007-04-24 01:23:45
Changes

  1. icomment:
    Logged In: YES 
    user_id=75003
    Originator: NO
    
    Miguel, the extCmdMapPtr leak is troublesome. The pointer is allocated in line 883, and while there was no code releasing it in "TclFreeCompileEnv" your change to it (line 997) should have no effect, this code should never be executed. Because in line 2200 the pointer is transfered to a different structure, the "lineBCPtr"-Tcl_HashTable in the Interp* structure. The pointer in the compile environment is set to NULL at that point. The lineBCPtr hash is allocated in line 390 of "tclBasic.c". Release of elements happens in either lines 1310ff of the same file, or in "TclCleanupByteCode", in file "tclCompile.c", line 785ff. These are the two places where extCmdMapPtr should be released, as part of the hash entry.
    
    The only way I can see extCmdMapPtr leaking is if the ByteCode of some Tcl code itself is not released. 
    
    
    
  2. login: "andreas_kupries"
  3. mimetype: "text/plain"
  4. username: "andreas_kupries"