Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 8cadf12d2f19ca88ec4a338a046bc4170cdf0760f5df5f47882ccb8152bd2f94
Ticket: a97680cbed27a3bb26b82800cdfd662064aa1587
Tcl_FSJoinToPath(): outdated comment
User & Date: chrstphrchvz on 2023-07-25 20:57:43
Changes

  1. assignee changed to: "nobody"
  2. closer changed to: "nobody"
  3. cmimetype changed to: "text/x-fossil-wiki"
  4. comment changed to:
    The comment documenting <tt>Tcl_FSJoinToPath()</tt> says:
    <pre>
     *	The objects in the array given will temporarily have their refCount
     *	increased by one, and then decreased by one when this function exits
     *	(which means if they had zero refCount when we were called, they will
     *	be freed).
    </pre>
    
    This appears to be outdated. It has been documented in 8.7 ([62834021ed4c], [https://www.tcl-lang.org/man/tcl8.7/TclLib/FileSystem.html#M47]) that the reference counts of values in the <tt>objv</tt> array must be nonzero. Those reference counts used to be temporarily incremented by <tt>Tcl_ListObjAppendElement()</tt>, but that was removed in [55c8c6c1552f], and <tt>TclJoinPath()</tt> currently seems to leave reference counts of inputs as-is.
    
  5. foundin changed to: "8.6.13"
  6. is_private changed to: "0"
  7. login: "chrstphrchvz"
  8. priority changed to: "5 Medium"
  9. private_contact changed to: "6133eb3026f9b10aa9b7b48da92ae2834fc225b0"
  10. resolution changed to: "None"
  11. severity changed to: "Minor"
  12. status changed to: "Open"
  13. submitter changed to: "chrstphrchvz"
  14. subsystem changed to: "37. File System"
  15. title changed to: "Tcl_FSJoinToPath(): outdated comment"
  16. type changed to: "Bug"