Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: e68e1974c2ab80a5ce4000e0b543a6b1eb21fe9e
Ticket: 7368d225a657380c364ceb3fcf814bdba374a566
Tcl_SetVar2() leaks memory
User & Date: dgp on 2014-07-10 14:40:59
Changes

  1. assignee changed to: "nobody"
  2. closer changed to: "nobody"
  3. cmimetype changed to: "text/plain"
  4. comment changed to:
    Tcl_SetVar2() creates the (Tcl_Obj) value out of
    the (const char *) data it receives, then passes
    it on to Tcl_SetVar2Ex() to manage the rest of its
    lifetime.  
    
    This mostly works, so long as Tcl_SetVar2Ex() stores
    the value in a variable.
    
    When flags includes TCL_APPEND_VALUE and does not include
    TCL_LIST_ELEMENT that does not happen and the mem leaks.
    There may be other leak scenarios too.
    
    The testing package pkgua exposes this, when examined with
    valgrind.
    
  5. foundin changed to: "8.5"
  6. is_private changed to: "0"
  7. login: "dgp"
  8. priority changed to: "5 Medium"
  9. resolution changed to: "None"
  10. severity changed to: "Minor"
  11. status changed to: "Open"
  12. submitter changed to: "dgp"
  13. subsystem changed to: "07. Variables"
  14. title changed to: "Tcl_SetVar2() leaks memory"
  15. type changed to: "Bug"