diff options
author | Paul Sherwood <paul.sherwood@codethink.co.uk> | 2014-04-29 20:37:28 +0000 |
---|---|---|
committer | Paul Sherwood <paul.sherwood@codethink.co.uk> | 2014-04-29 20:37:28 +0000 |
commit | e98c205a5c3fb893ffdda3f5e05d1967b4a79c1d (patch) | |
tree | 3ecbd4f05ab9601cefa7b322323039795db440a9 /prompt.c | |
parent | 43efcf42382e87de4aa423e5e1607958ad1717d0 (diff) | |
parent | 0bc85abb7aa9b24b093253018801a0fb43d01122 (diff) | |
download | git-baserock/ps/update-git.tar.gz |
Merge tag 'v1.9.2' into HEADbaserock/ps/update-git
Git 1.9.2
Diffstat (limited to 'prompt.c')
-rw-r--r-- | prompt.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -22,6 +22,7 @@ static char *do_askpass(const char *cmd, const char *prompt) if (start_command(&pass)) return NULL; + strbuf_reset(&buffer); if (strbuf_read(&buffer, pass.out, 20) < 0) err = 1; @@ -38,7 +39,7 @@ static char *do_askpass(const char *cmd, const char *prompt) strbuf_setlen(&buffer, strcspn(buffer.buf, "\r\n")); - return strbuf_detach(&buffer, NULL); + return buffer.buf; } char *git_prompt(const char *prompt, int flags) |