From 61dc4f42b346931b5a67da4f46013fd5e2fb6ad3 Mon Sep 17 00:00:00 2001 From: Xavier Del Campo Romero Date: Mon, 6 Mar 2023 05:24:13 +0100 Subject: Perform some minor optimizations --- main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'main.c') diff --git a/main.c b/main.c index 5175f00..690fcda 100644 --- a/main.c +++ b/main.c @@ -898,7 +898,7 @@ static int createdir(const struct http_payload *const p, { .status = HTTP_STATUS_BAD_REQUEST, .buf.ro = body, - .n = strlen(body) + .n = sizeof body - 1 }; if (http_response_add_header(r, "Content-Type", "text/html")) -- cgit v1.2.3