mirror of
https://github.com/git/git
synced 2024-08-27 11:39:22 +00:00
Merge branch 'ma/bash-completion-leaking-x'
The completion script (in contrib/) contaminated global namespace and clobbered on a shell variable $x. * ma/bash-completion-leaking-x: completion: fix global bash variable leak on __gitcompappend
This commit is contained in:
commit
6b1258b07b
|
@ -186,7 +186,7 @@ fi
|
|||
|
||||
__gitcompappend ()
|
||||
{
|
||||
local i=${#COMPREPLY[@]}
|
||||
local x i=${#COMPREPLY[@]}
|
||||
for x in $1; do
|
||||
if [[ "$x" == "$3"* ]]; then
|
||||
COMPREPLY[i++]="$2$x$4"
|
||||
|
|
Loading…
Reference in a new issue