summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMikhail Burakov <mburakov@mailbox.org>2022-01-11 12:20:52 +0100
committerMikhail Burakov <mburakov@mailbox.org>2022-01-11 12:20:52 +0100
commit92885e110f12aaf3890b4da63a2036cfb0602fc2 (patch)
tree1fa3beb3264c72cfdbd867387b0fc8873ae86fb0
parentcb13bc78683859621d5280c72add307b4b1e313d (diff)
Use proper type for pointers difference
-rw-r--r--uhttp.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/uhttp.c b/uhttp.c
index 9e6ec6f..1d7e190 100644
--- a/uhttp.c
+++ b/uhttp.c
@@ -167,7 +167,7 @@ static _Bool UhttpOnFieldValue(struct Uhttp* uhttp, char* glyph) {
static _Bool UhttpOnBody(struct Uhttp* uhttp, char* glyph) {
if (!uhttp->public.body) uhttp->public.body = glyph;
- ssize_t body_size = glyph - uhttp->public.body + 1;
+ ptrdiff_t body_size = glyph - uhttp->public.body + 1;
if ((size_t)body_size == uhttp->public.body_size)
uhttp->parser.state = UhttpOnStopped;
return 1;