diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2015-05-26 12:44:35 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2015-05-26 12:44:35 (GMT) |
commit | a2f1e1a431e3224256bbf26f863fd5547a1ebe1d (patch) | |
tree | 76af378310ab2c3911876ebb6cd43c621b703736 /library/tkfbox.tcl | |
parent | 20ece3ffdaf1e1db267594e9601960065b268244 (diff) | |
parent | c6310d2a325a8284e036acb3a4aa269414a22e09 (diff) | |
download | tk-a2f1e1a431e3224256bbf26f863fd5547a1ebe1d.zip tk-a2f1e1a431e3224256bbf26f863fd5547a1ebe1d.tar.gz tk-a2f1e1a431e3224256bbf26f863fd5547a1ebe1d.tar.bz2 |
Fix [1641721]: tk_getOpenFile shows symlinks to directories twice.
Diffstat (limited to 'library/tkfbox.tcl')
-rw-r--r-- | library/tkfbox.tcl | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/library/tkfbox.tcl b/library/tkfbox.tcl index 6604575..a52465a 100644 --- a/library/tkfbox.tcl +++ b/library/tkfbox.tcl @@ -1169,6 +1169,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 } } @@ -1176,7 +1180,6 @@ proc ::tk::dialog::file::GlobFiltered {dir type {overrideFilter 0}} { } proc ::tk::dialog::file::CompleteEnt {w} { - variable showHiddenVar upvar ::tk::dialog::file::[winfo name $w] data set f [$data(ent) get] if {$data(-multiple)} { |