git-gui: Ensure submodule path is quoted properly

When quoting an arbitrary user string in Tcl, its better to use
[list ...] than to use {...}, in case the user string has spaces
or { embedded within it.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
maint
Shawn O. Pearce 2009-08-26 17:39:45 -07:00
parent af413de47b
commit 118d938812
1 changed files with 2 additions and 2 deletions

View File

@ -300,9 +300,9 @@ proc start_show_diff {cont_info {add_opts {}}} {
|| [string match {160000 *} [lindex $s 3]]} {
set is_submodule_diff 1
if {$w eq $ui_index} {
set cmd {submodule summary --cached -- $current_diff_path}
set cmd [list submodule summary --cached -- $path]
} else {
set cmd {submodule summary --files -- $current_diff_path}
set cmd [list submodule summary --files -- $path]
}
}