diff options
author | dgp <dgp@users.sourceforge.net> | 2012-07-25 15:03:02 (GMT) |
---|---|---|
committer | dgp <dgp@users.sourceforge.net> | 2012-07-25 15:03:02 (GMT) |
commit | 81f96df6176c44d1f7159a0fbcb8bd4c68c0c94d (patch) | |
tree | 102f45919dfd6db170dbccb414845132439e1590 /library/init.tcl | |
parent | 4eef2a8f1f3ceb740cfca5f5b7e991fece4740e7 (diff) | |
parent | 3b6f6e4d4166d6ba00d2886efd6136f30e906f82 (diff) | |
download | tcl-81f96df6176c44d1f7159a0fbcb8bd4c68c0c94d.zip tcl-81f96df6176c44d1f7159a0fbcb8bd4c68c0c94d.tar.gz tcl-81f96df6176c44d1f7159a0fbcb8bd4c68c0c94d.tar.bz2 |
merge 8.5core_8_5_12core_8_5_12_rc
Diffstat (limited to 'library/init.tcl')
-rw-r--r-- | library/init.tcl | 13 |
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]] |