From d82e42872304b6c2225698ce45d32f7dcdba2764 Mon Sep 17 00:00:00 2001 From: Simon Goldschmidt Date: Fri, 8 May 2026 21:54:16 +0200 Subject: [PATCH] httpd: fix compiling last commit with LWIP_HTTPD_HEADERS_BEFORE_FILE_OPEN==0 --- src/apps/http/httpd.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/apps/http/httpd.c b/src/apps/http/httpd.c index 8c74eb3b..7c47ebac 100644 --- a/src/apps/http/httpd.c +++ b/src/apps/http/httpd.c @@ -2131,12 +2131,12 @@ http_parse_request(struct pbuf *inp, struct http_state *hs, struct altcp_pcb *pc } else #endif /* LWIP_HTTPD_SUPPORT_POST */ { -#if LWIP_HTTPD_HEADERS_BEFORE_FILE_OPEN err_t err; +#if LWIP_HTTPD_HEADERS_BEFORE_FILE_OPEN void *obj; char replace_uri[LWIP_HTTPD_HEADERS_URI_REPLACE_LEN + 1]; replace_uri[0] = 0; - obj = httpd_headers_before_file_open(crlf + 2, data_len - (crlf + 2 - data), + obj = httpd_headers_before_file_open(crlf + 2, (uint16_t)(data_len - (crlf + 2 - data)), uri, replace_uri, LWIP_HTTPD_HEADERS_URI_REPLACE_LEN); if (replace_uri[0] != 0) { @@ -2146,7 +2146,7 @@ http_parse_request(struct pbuf *inp, struct http_state *hs, struct altcp_pcb *pc err = http_find_file(hs, uri, is_09); #if LWIP_HTTPD_HEADERS_AFTER_FILE_OPEN if (err == ERR_OK) { - httpd_headers_after_file_open(hs->handle, crlf + 2, data_len - (crlf + 2 - data) + httpd_headers_after_file_open(hs->handle, crlf + 2, (uint16_t)(data_len - (crlf + 2 - data)) #if LWIP_HTTPD_HEADERS_BEFORE_FILE_OPEN , obj #endif /* LWIP_HTTPD_HEADERS_BEFORE_FILE_OPEN */