git-gui: Don't prepend the prefix if value looks like a full path
When argument parsing fails to detect a file name, "git-gui" will try to use the previously detected "head" as the file name. We should avoid prepending the prefix if "head" looks like a full path. Signed-off-by: Andrew Wong <andrew.kw.w@gmail.com> Signed-off-by: Pat Thoyts <patthoyts@users.sourceforge.net>
This commit is contained in:
parent
e3d06ca93e
commit
df46eda388
@ -3037,9 +3037,14 @@ blame {
|
|||||||
unset is_path
|
unset is_path
|
||||||
|
|
||||||
if {$head ne {} && $path eq {}} {
|
if {$head ne {} && $path eq {}} {
|
||||||
|
if {[string index $head 0] eq {/}} {
|
||||||
|
set path [normalize_relpath $head]
|
||||||
|
set head {}
|
||||||
|
} else {
|
||||||
set path [normalize_relpath $_prefix$head]
|
set path [normalize_relpath $_prefix$head]
|
||||||
set head {}
|
set head {}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if {$head eq {}} {
|
if {$head eq {}} {
|
||||||
load_current_branch
|
load_current_branch
|
||||||
|
Loading…
Reference in New Issue
Block a user