summaryrefslogtreecommitdiffstats
path: root/library
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2015-05-26 12:35:23 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2015-05-26 12:35:23 (GMT)
commita05d1fea7d8d233f5b557a5645d5a996cc33a0b2 (patch)
tree05c003eefe05805fe71882ccb84470e6f4738800 /library
parentd1c48d32205766e74234558200f846f04f04c2ae (diff)
downloadtk-a05d1fea7d8d233f5b557a5645d5a996cc33a0b2.zip
tk-a05d1fea7d8d233f5b557a5645d5a996cc33a0b2.tar.gz
tk-a05d1fea7d8d233f5b557a5645d5a996cc33a0b2.tar.bz2
Fix [1641721]: tk_getOpenFile shows symlinks to directories twice.
Diffstat (limited to 'library')
-rw-r--r--library/tkfbox.tcl4
1 files changed, 4 insertions, 0 deletions
diff --git a/library/tkfbox.tcl b/library/tkfbox.tcl
index e145805..fd0f6d7 100644
--- a/library/tkfbox.tcl
+++ b/library/tkfbox.tcl
@@ -1896,6 +1896,10 @@ proc ::tk::dialog::file::GlobFiltered {dir type {overrideFilter 0}} {
if {$f eq "." || $f eq ".."} {
continue
}
+ # See ticket [1641721], $f might be a link pointing to a dir
+ if {$type != "d" && [file isdir [file join $dir $f]]} {
+ continue
+ }
lappend result $f
}
}