Andrew's git
/
gitweb.git
/ diff
summary
|
log
|
commit
| diff |
tree
commit
grep
author
committer
pickaxe
?
re
git-prompt.sh: make $f local to __git_eread()
author
Justin Guenther
<jguenther@gmail.com>
Fri, 12 Dec 2014 21:59:56 +0000
(15:59 -0600)
committer
Junio C Hamano
<gitster@pobox.com>
Fri, 12 Dec 2014 23:13:37 +0000
(15:13 -0800)
This function uses (non-local) $f to store the value of its first parameter.
This can interfere with the user's environment.
Signed-off-by: Justin Guenther <jguenther@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
contrib/completion/git-prompt.sh
patch
|
blob
|
history
raw
|
patch
| inline |
side by side
(parent:
59d3924
)
diff --git
a/contrib/completion/git-prompt.sh
b/contrib/completion/git-prompt.sh
index 54489080f8ae25a4483cd4bae076942f47f53031..dba928ed00458cae9987e2bdbbad324827435ad3 100644
(file)
--- a/
contrib/completion/git-prompt.sh
+++ b/
contrib/completion/git-prompt.sh
@@
-261,7
+261,7
@@
__git_ps1_colorize_gitstring ()
eread ()
{
- f="$1"
+
local
f="$1"
shift
test -r "$f" && read "$@" <"$f"
}