Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: b4184d92c90b03fc530d7c30ed04e51355e71611
Ticket: 2903188fffffffffffffffffffffffffffffffff
Tcl crashes when debugging with Komodo
User & Date: evilmike on 2009-12-12 17:42:22
Changes

  1. icomment:
    If it is ok for Tcl_FindHashEntry to return NULL values, then there are several functions where the return value is not checked for it:
    Tcl_LogCommandInfo (tclNamesp.c:6977)
    UnsetVarStruct (tclVar.c:2350)
    UnsetVarStruct (tclVar.c:2379)
    Tcl_ArrayObjCmd (tclVar.c:2862)
    ParseSearchId (tclVar.c:4301)
    DeleteSearches (tclVar.c:4343)
    TclDeleteNamespaceVars (tclVar.c:4413)
    DeleteArray (tclVar.c:4604)
    
    All of these functions call Tcl_GetHashValue before checking for Null.
    I am not saying this is generally wrong, since i can not know when a hash entry is garantied to exist. But it can potentially crash.
    Till now I had crashes in DeleteSearches and in UnsetVarStruct exactly when those functions tried to dereference a NUL pointer via Tcl_GetHashValue.
    
    
    
  2. login: "evilmike"
  3. mimetype: "text/plain"
  4. username: "evilmike"