Artifacts Associated With Ticket 655300
Ticket change [f484163141] (rid 129935) by dgp on 2002-12-17 17:33:00:
- assignee initialized to: "hobbs"
- cmimetype initialized to: "text/plain"
- comment initialized to:
The docs for Tcl_MakeSafe say: Tcl_MakeSafe makes interp ``safe'' by removing all non-core and core unsafe functionality. Note that if you call this after adding some extension to an interpreter, all traces of that extension will be removed from the interpreter. It's not exactly clear to me what magical package unloading power is claimed for Tcl_MakeSafe, but it's clear that Tcl_MakeSafe doesn't have it. Consider: Tcl_Interp *i = Tcl_CreateInterp(); Tcl_Eval(i, "package require Tk"); Tcl_MakeSafe(i); At this point the Tk commands (both safe and unsafe) will still be defined in i. - foundin initialized to: "obsolete: 8.4.1"
- priority initialized to: "5 Medium"
- resolution initialized to: "None"
- status initialized to: "Open"
- submitter initialized to: "dgp"
- subsystem initialized to: "20. [interp]"
- title initialized to: "Tcl_MakeSafe docs confusing/wrong"
- type initialized to: "RFE"
Ticket change [6ee1f36894] (rid 100215) by dkf on 2002-12-18 00:41:35:
- icomment:
Logged In: YES user_id=79902 Does anything need safe interps that are not slaves of full-blooded masters? If not, the only correct way of using this API is through Tcl_CreateSlave() and Tcl_MakeSafe would be better not exposed at all.
- login: "dkf"
- mimetype: "text/plain"
- username: "dkf"
- icomment:
Ticket change [e7c718f3e6] (rid 104527) by dgp on 2002-12-18 00:53:48:
- icomment:
Logged In: YES user_id=80530 "need" is pretty strong. Seems wasteful to be forced to create an unsafe master when all one wants is a safe interp, though. Then again, we don't really "need" safe interps; one can always delete commands from an interp based on one's own judgment about safety/utility. Agree that a public Tcl_MakeSafe() doesn't seem like a good idea though, since it allows any extension to mark an interp as "safe" without any guarantee that all unsafe stuff is removed. Does Tcl_MakeSafe have any callers outside of Tcl itself?
- login: "dgp"
- mimetype: "text/plain"
- username: "dgp"
- icomment:
Ticket change [13a5723948] (rid 124260) by dgp on 2003-04-14 11:14:58:
- priority changed to: "7 High"
Ticket change [9d43efb992] (rid 96272) by dgp on 2003-07-16 22:41:54:
- assignee changed to: "dkf"
- icomment:
Logged In: YES user_id=80530 any ideas for cleaning this up for 8.4.4 ?
- login: "dgp"
- mimetype: "text/plain"
- priority changed to: "9 Immediate"
- username: "dgp"
Ticket change [3da93b175e] (rid 121126) by dkf on 2003-07-17 04:05:39:
- icomment:
Logged In: YES user_id=79902 I'd be tempted to make it undocumented, perhaps with a new TclMakeSafe() in tclInt.decls in case someone is relying on it actually being there. I'm not sure whether we're allowed to do that in a point release though ;^)
- login: "dkf"
- mimetype: "text/plain"
- username: "dkf"
- icomment:
Ticket change [e1f9f33e91] (rid 87540) by dkf on 2003-07-17 04:36:24:
- assignee changed to: "dgp"
- icomment:
Logged In: YES user_id=79902 Documentation is now fixed, but leaving open as Tcl_MakeSafe is a candidate for removal from the public API; the only client I know of is Tcl_CreateSlave (and then only when it is asked to create a safe slave.)
- login: "dkf"
- mimetype: "text/plain"
- priority changed to: "5 Medium"
- resolution changed to: "Fixed"
- username: "dkf"
Ticket change [6ca11a0b12] (rid 128548) by dgp on 2003-07-17 10:32:23:
- foundin changed to: "obsolete: 8.4.3"
- icomment:
Logged In: YES user_id=80530 Interesting discussion on the Tclers' chat and consultation with the Tcl 7.6 source code revealed that Tcl_MakeSafe once behaved as documented. Behavior changed starting with Tcl 8, but the docs were not changed. Seems likely the behavior change was a bug.
- login: "dgp"
- mimetype: "text/plain"
- priority changed to: "9 Immediate"
- username: "dgp"
Ticket change [b6bb14ab95] (rid 125468) by dgp on 2003-07-18 22:23:30:
- assignee changed to: "nobody"
- foundin changed to: "None"
- icomment:
Logged In: YES user_id=80530 Softened the deprecation warning in the modified docs for 8.4.4. I think the remaining issue is a desire of some to restore the Tcl 7 behavior. Converting to an RFE...
- login: "dgp"
- mimetype: "text/plain"
- priority changed to: "5 Medium"
- resolution changed to: "Remind"
- subsystem changed to: "None"
- title changed to: "restore Tcl 7 compatibility of Tcl_MakeSafe"
- username: "dgp"
Ticket change [54c1055545] (rid 94003) by dgp on 2003-07-18 22:24:45:
- subsystem changed to: "20. [interp]"
Ticket change [fb53524200] (rid 92042) by dgp on 2003-07-18 22:26:59:
- assignee changed to: "hobbs"
Ticket change [7e76721c3e] (rid 199952) by jan.nijtmans on 2022-04-05 07:02:08:
- assignee changed to: "jan.nijtmans"
- closer changed to: "nobody"
- comment changed to:
The docs for Tcl_MakeSafe say: Tcl_MakeSafe makes interp ``safe'' by removing all non-core and core unsafe functionality. Note that if you call this after adding some extension to an interpreter, all traces of that extension will be removed from the interpreter. It's not exactly clear to me what magical package unloading power is claimed for Tcl_MakeSafe, but it's clear that Tcl_MakeSafe doesn't have it. Consider: Tcl_Interp *i = Tcl_CreateInterp(); Tcl_Eval(i, "package require Tk"); Tcl_MakeSafe(i); At this point the Tk commands (both safe and unsafe) will still be defined in i. - login: "jan.nijtmans"
- mimetype: "text/plain"
- severity changed to: "Minor"
Ticket change [c152e6692a] (rid 204694) by jan.nijtmans on 2022-09-26 11:03:36:
- closedate changed to: "2459848.96083767"
- closer changed to: "jan.nijtmans"
- foundin changed to: "8.6"
- icomment:
Handled by [https://core.tcl-lang.org/tips/doc/trunk/tip/624.md|TIP #624]. Tcl_MakeSafe will be gone in Tcl 9.0, so no worries any more.
- login: "jan.nijtmans"
- mimetype: "text/x-fossil-wiki"
- resolution changed to: "Fixed"
- status changed to: "Closed"