aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorXavier Del Campo Romero <xavi.dcr@tutanota.com>2023-03-04 04:04:09 +0100
committerXavier Del Campo Romero <xavi.dcr@tutanota.com>2023-03-04 04:04:09 +0100
commit8319dfe58b99f44f52abd0e4db0f6a0200207a1a (patch)
tree409e060f066c2f37e597b1f3c5e1ae500a8efd6b
parentfff6ed4e0a656a89c787a6461cd8a29eec3d0a71 (diff)
downloadslcl-8319dfe58b99f44f52abd0e4db0f6a0200207a1a.tar.gz
http.c: Compare headers as case-insensitive
Web browsers such as lynx send "Content-length" instead of "Content-Length" (as done by LibreWolf and Chromium).
-rw-r--r--http.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/http.c b/http.c
index 71a872e..5c4626b 100644
--- a/http.c
+++ b/http.c
@@ -790,7 +790,7 @@ static int process_header(struct http_ctx *const h, const char *const line,
const struct header *const hdr = &headers[i];
int ret;
- if (!strncmp(line, hdr->header, n) && (ret = hdr->f(h, value)))
+ if (!strncasecmp(line, hdr->header, n) && (ret = hdr->f(h, value)))
return ret;
}