Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 8c9ade487a16fbc803b244c71507a99eaaed693fbafd971bfa4755db6c26ff55
Ticket: 578155d5a19b348dc1a9fe96cc2c067a59326a89
Very rare bug (segfault) if set variable (with error case) using self-releasable object as new value
User & Date: pooryorick on 2023-03-31 15:27:04
Changes

  1. closedate changed to: "2460035.14380361"
  2. icomment:
    "nominal condition of every function in error case (here value is not assigned to variable, dict or whatever) is don't touch the value,"
    
    <blockquote>
    No, a function that receives a Tcl_Obj may increment the reference count and then decrement it again.  The caller can protect itself from the effect by incrementing the reference count before calling the function, and decrementing it later.  sebres is conflating the idea that at the script-level a variable value nominally remains untouched with the false idea that a Tcl_Obj reference count also remains untouched.
    </blockquote>
    
  3. login: "pooryorick"
  4. mimetype: "text/x-fossil-wiki"