summaryrefslogtreecommitdiffstats
path: root/library/init.tcl
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2012-07-25 15:03:02 (GMT)
committerdgp <dgp@users.sourceforge.net>2012-07-25 15:03:02 (GMT)
commit643148e686b700852b7d0196180f28e185a13a5a (patch)
tree102f45919dfd6db170dbccb414845132439e1590 /library/init.tcl
parent22613b0163fb3cbdaff6dabb029940fc526ca918 (diff)
parentf2ef7ef78982c2be84ab1ad8a4a3d99592133946 (diff)
downloadtcl-643148e686b700852b7d0196180f28e185a13a5a.zip
tcl-643148e686b700852b7d0196180f28e185a13a5a.tar.gz
tcl-643148e686b700852b7d0196180f28e185a13a5a.tar.bz2
merge 8.5
Diffstat (limited to 'library/init.tcl')
-rw-r--r--library/init.tcl13
1 files changed, 8 insertions, 5 deletions
diff --git a/library/init.tcl b/library/init.tcl
index f6dfdba..16957b3 100644
--- a/library/init.tcl
+++ b/library/init.tcl
@@ -698,11 +698,14 @@ proc auto_execok name {
}
}
- foreach dir [split $path {;}] {
- # Skip already checked directories
- if {[info exists checked($dir)] || ($dir eq {})} { continue }
- set checked($dir) {}
- foreach ext $execExtensions {
+ foreach ext $execExtensions {
+ unset -nocomplain checked
+ foreach dir [split $path {;}] {
+ # Skip already checked directories
+ if {[info exists checked($dir)] || ($dir eq {})} {
+ continue
+ }
+ set checked($dir) {}
set file [file join $dir ${name}${ext}]
if {[file exists $file] && ![file isdirectory $file]} {
return [set auto_execs($name) [list $file]]