summaryrefslogtreecommitdiffstats
path: root/library/safe.tcl
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2021-03-19 10:49:13 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2021-03-19 10:49:13 (GMT)
commitc39345b47aa9604e3ffb82599ee15be9cbce57f6 (patch)
tree6ea0f630f39d29e8655fe1ad1a61ee6316dd90aa /library/safe.tcl
parentf2cb38dda94341ddbb64b3b72efdeeb62ec610be (diff)
parentfff5060d945d7ee8f74e84dea9b0f703e2bae424 (diff)
downloadtcl-c39345b47aa9604e3ffb82599ee15be9cbce57f6.zip
tcl-c39345b47aa9604e3ffb82599ee15be9cbce57f6.tar.gz
tcl-c39345b47aa9604e3ffb82599ee15be9cbce57f6.tar.bz2
Merge 8.6
Diffstat (limited to 'library/safe.tcl')
-rw-r--r--library/safe.tcl24
1 files changed, 12 insertions, 12 deletions
diff --git a/library/safe.tcl b/library/safe.tcl
index 2ee4531..27033b2 100644
--- a/library/safe.tcl
+++ b/library/safe.tcl
@@ -1009,8 +1009,8 @@ proc ::safe::AliasLoad {child file args} {
return -code error $msg
}
- # package name (can be empty if file is not).
- set package [lindex $args 0]
+ # prefix (can be empty if file is not).
+ set prefix [lindex $args 0]
namespace upvar ::safe [VarName $child] state
@@ -1022,23 +1022,23 @@ proc ::safe::AliasLoad {child file args} {
# authorize that.
if {!$state(nestedok)} {
Log $child "loading to a sub interp (nestedok)\
- disabled (trying to load $package to $target)"
+ disabled (trying to load $prefix to $target)"
return -code error "permission denied (nested load)"
}
}
# Determine what kind of load is requested
if {$file eq ""} {
- # static package loading
- if {$package eq ""} {
- set msg "load error: empty filename and no package name"
+ # static library loading
+ if {$prefix eq ""} {
+ set msg "load error: empty filename and no prefix"
Log $child $msg
return -code error $msg
}
if {!$state(staticsok)} {
- Log $child "static packages loading disabled\
- (trying to load $package to $target)"
- return -code error "permission denied (static package)"
+ Log $child "static library loading disabled\
+ (trying to load $prefix to $target)"
+ return -code error "permission denied (static library)"
}
} else {
# file loading
@@ -1061,10 +1061,10 @@ proc ::safe::AliasLoad {child file args} {
}
try {
- return [::interp invokehidden $child load $file $package $target]
+ return [::interp invokehidden $child load $file $prefix $target]
} on error msg {
- # Some packages return no error message.
- set msg0 "load of binary library for package $package failed"
+ # Some libraries return no error message.
+ set msg0 "load of library for prefix $prefix failed"
if {$msg eq {}} {
set msg $msg0
} else {