aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2023-06-24 15:05:06 -0700
committerJunio C Hamano <gitster@pobox.com>2023-06-24 15:05:06 -0700
commit94486b6763c29144c60932829a65fec0597e17b3 (patch)
treee20a1df83184b47ff595150e06426a70d19548d2
parentThe fourth batch (diff)
parentMerge branch 'jk/redact-h2h3-headers-fix' into maint-2.41 (diff)
downloadgit-94486b6763c29144c60932829a65fec0597e17b3.tar.gz
git-94486b6763c29144c60932829a65fec0597e17b3.zip
Merge branch 'maint'
* maint: http: handle both "h2" and "h2h3" in curl info lines
-rw-r--r--http.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/http.c b/http.c
index bb58bb3e6a..b71bb1e3ad 100644
--- a/http.c
+++ b/http.c
@@ -746,7 +746,8 @@ static void redact_sensitive_info_header(struct strbuf *header)
* h2h3 [<header-name>: <header-val>]
*/
if (trace_curl_redact &&
- skip_iprefix(header->buf, "h2h3 [", &sensitive_header)) {
+ (skip_iprefix(header->buf, "h2h3 [", &sensitive_header) ||
+ skip_iprefix(header->buf, "h2 [", &sensitive_header))) {
if (redact_sensitive_header(header, sensitive_header - header->buf)) {
/* redaction ate our closing bracket */
strbuf_addch(header, ']');