Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: f07dffe0871c349da6ddc5ec50318112cf146ee8153ac43227753ca5f72a0222
Ticket: 167e0635db79f05d23d766376f6eed32b1572451
`make valgrind` detections
User & Date: sebres on 2024-04-12 22:24:05
Changes

  1. icomment:
    The bug in tclHash is ultimately fixed now across all affected branches:<br/>
    8.5 - [969a185ea4d19037] to 9.0 - [c3c498a6a853f3b8].
    
    This was really heavy bug - create/find hash entry had mistakenly compare pointer with a content, invalid for all non-pointer hash-types, containing data (strings/arrays) directly in the hash key.
    
    Well, fortunately Dons valgrind was better than my, and finally it came to light...
    And thanks for your obstinacy, Don.
    
    I'm also sure the complain would disappear now (also without [0e273ad998f16100]).
    
    > <i>The routine ClockFmtScnStorageAllocProc also has a memset() call.</i>
    
    This memset only resets the part responsible for ClockFmtScnStorage... 
    So after all by empty format (1 byte long, NTS) it contains 3 (x86) or 7 (x64) uninitialized bytes in key.
    (And it was a good thing, otherwise that bug would be never found and caused extremely rare heisenbug on some constellation for containing data key types).
    
    
    > <i>I did not attempt to review the calculations of allocsize.</i>
    
    Everything must be correct there, but I could rewrite it more clear.
    
  2. login: "sebres"
  3. mimetype: "text/x-fossil-wiki"