Andrew's git
/
gitweb.git
/ diff
summary
|
log
|
commit
| diff |
tree
commit
grep
author
committer
pickaxe
?
re
Merge branch 'ma/bash-completion-leaking-x' into maint
author
Junio C Hamano
<gitster@pobox.com>
Mon, 27 Apr 2015 19:23:51 +0000
(12:23 -0700)
committer
Junio C Hamano
<gitster@pobox.com>
Mon, 27 Apr 2015 19:23:51 +0000
(12:23 -0700)
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
contrib/completion/git-completion.bash
patch
|
blob
|
history
raw
(from parent 1:
631f6f1
)
diff --git
a/contrib/completion/git-completion.bash
b/contrib/completion/git-completion.bash
index 661a8294dac162f0e50ccfe588847bb45b572143..16205467b1303100b5d67f55371aff749ff5c57d 100644
(file)
--- a/
contrib/completion/git-completion.bash
+++ b/
contrib/completion/git-completion.bash
@@
-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"