summaryrefslogtreecommitdiff
path: root/strbuf.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2018-01-05 21:28:10 (GMT)
committerJunio C Hamano <gitster@pobox.com>2018-01-05 21:28:10 (GMT)
commita741e2825b3a3045254f404696c0051714c0e7c3 (patch)
treed15baf9081e6518009d5434a20a68cef2499afb9 /strbuf.c
parent843d94b3cd30e61c7c4879f9bc6d013021b9350a (diff)
parent4c267f2ae37e5b5f834172f04b7dd4343e370689 (diff)
downloadgit-a741e2825b3a3045254f404696c0051714c0e7c3.zip
git-a741e2825b3a3045254f404696c0051714c0e7c3.tar.gz
git-a741e2825b3a3045254f404696c0051714c0e7c3.tar.bz2
Merge branch 'jd/fix-strbuf-add-urlencode-bytes'
Bytes with high-bit set were encoded incorrectly and made credential helper fail. * jd/fix-strbuf-add-urlencode-bytes: strbuf: fix urlencode format string on signed char
Diffstat (limited to 'strbuf.c')
-rw-r--r--strbuf.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/strbuf.c b/strbuf.c
index 8007be8..1df674e 100644
--- a/strbuf.c
+++ b/strbuf.c
@@ -683,7 +683,7 @@ static void strbuf_add_urlencode(struct strbuf *sb, const char *s, size_t len,
(!reserved && is_rfc3986_reserved(ch)))
strbuf_addch(sb, ch);
else
- strbuf_addf(sb, "%%%02x", ch);
+ strbuf_addf(sb, "%%%02x", (unsigned char)ch);
}
}