Overview
| Artifact ID: | 6d0ad0c188c9e29e94cf03d8daa04fb59097ddb3d4dfac48ce847d164cd74436 |
|---|---|
| Ticket: | ba7491332a89da45d62f583e4ac848afcc89dd57
Tcl_Panic from Itcl_SafeInit |
| User & Date: | christian.nassau on 2021-09-21 08:33:23 |
Changes
- assignee changed to: "nobody"
- closer changed to: "nobody"
- cmimetype changed to: "text/plain"
- comment changed to:
The itcl initialization code has room for improvement. The worst problem is that it is very easy to trigger a Tcl panic by trying to load the Itcl package: it suffices to create the itcl namespace beforehand. This code is also reached from Itcl_SafeInit so it can even be used to crash Tcl from a safe interpreter: /$ bin/tclsh8.6 % namespace eval itcl { set some variable } variable % package req itcl Itcl: cannot create namespace: "::itcl" Aborted (core dumped) A second point is that it seems unnecessarily difficult to get the location of the "itcl.tcl" initialization file right. I believe the "itcl.tcl" should reside next to the library that needs it, so its location could (= should) be set in the pkgIndex.tcl file, using e.g. package ifneeded itcl 4.2.1 "[list set ::env(ITCL_LIBRARY) $dir];[list load [file join $dir "libitcl4.2.1.so"] Itcl]" - foundin changed to: "Itcl 4.2.1"
- is_private changed to: "0"
- login: "christian.nassau"
- priority changed to: "5 Medium"
- private_contact changed to: "3b279cda57135cd36d2c32c66396637342913651"
- resolution changed to: "None"
- severity changed to: "Severe"
- status changed to: "Open"
- submitter changed to: "christian.nassau"
- subsystem changed to: "81. Bundled Packages"
- title changed to: "Tcl_Panic from Itcl_SafeInit"
- type changed to: "Bug"