Skip to content

Commit

Permalink
fixup! Do not mask the username when reading credentials
Browse files Browse the repository at this point in the history
This fixes t0300 and t0302 which rely on GIT_ASKPASS to be respected
even when querying the username. And if those tests rely on that feature
we can be certain that other callers rely on it, too (think UIs).

Signed-off-by: Johannes Schindelin <[email protected]>
  • Loading branch information
dscho committed Mar 15, 2016
1 parent 9f3f612 commit 6134925
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions credential.c
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,8 @@ static void credential_getpass(struct credential *c)
{
if (!c->username)
c->username = credential_ask_one("Username", c,
(getenv("GIT_ASKPASS") ?
PROMPT_ASKPASS : 0) |
PROMPT_ECHO);
if (!c->password)
c->password = credential_ask_one("Password", c,
Expand Down

0 comments on commit 6134925

Please sign in to comment.