summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Kleshov <[email protected]>2025-04-02 10:22:43 +0300
committerMike Kleshov <[email protected]>2025-04-02 10:22:43 +0300
commitca0395c5ae54273b4fd542ef25b57d4b759678f8 (patch)
tree652a554414d729e1497ff87b562df7703a4b4a7f
parent31d8988f89699aa357b0468a700483ea340e9da9 (diff)
downloadlwip-master.tar.gz
Revert "Apply patch #10511: remove code with no effect in httpd.c"HEADmaster
This reverts commit f877b457a1bb759d48567326ec020be7e3a3d989.
-rw-r--r--src/apps/http/httpd.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/apps/http/httpd.c b/src/apps/http/httpd.c
index 48a4733..cf3abac 100644
--- a/src/apps/http/httpd.c
+++ b/src/apps/http/httpd.c
@@ -2118,6 +2118,12 @@ http_parse_request(struct pbuf *inp, struct http_state *hs, struct altcp_pcb *pc
struct pbuf *q = inp;
#endif /* LWIP_HTTPD_SUPPORT_REQUESTLIST */
err = http_post_request(q, hs, data, data_len, uri, sp2);
+ if (err != ERR_OK) {
+ /* restore header for next try */
+ *sp1 = ' ';
+ *sp2 = ' ';
+ uri[uri_len] = ' ';
+ }
if (err == ERR_ARG) {
goto badrequest;
}