Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 06f637206de8b03fee62bd2f8f108dde5510c6aa
Ticket: 3598150fffffffffffffffffffffffffffffffff
TclDStringToObj may trigger leak
User & Date: afredd on 2012-12-22 13:21:19
Changes

  1. assignee changed to: "nobody"
  2. cmimetype changed to: "text/plain"
  3. comment changed to:
    While skimming thro' the new 8.6 source code, i spotted
    something that lloked fishy in tclUtil.c.
    
    If TclDStringToObj() is called on a DString whose length is zero,
    but which has had its string allocated, then it still needs an
    explicit call to Tcl_DStringFree. The documentation suggests
    this is not necessary.
    
    It looks to me like the first if block: if (dsPtr->length == 0)
    is wrong and should be removed.
    
    
    I've not tested this, so i may be missing something obvious.
    
    Merry Xmas!
    
  4. foundin changed to: "current: 8.6.0"
  5. is_private changed to: "0"
  6. priority changed to: "5 Medium"
  7. resolution changed to: "None"
  8. status changed to: "Open"
  9. submitter changed to: "afredd"
  10. subsystem changed to: "None"
  11. title changed to: "TclDStringToObj may trigger leak"
  12. type changed to: "Bug"