1
0
mirror of https://github.com/lammertb/libhttp.git synced 2025-12-22 04:02:04 +03:00

Merge pull request #126 from kalphamon/patch-1

In a "bad request" reply, do not send back the content of the request in the reply
This commit is contained in:
bel2125
2015-05-19 21:55:04 +02:00

View File

@@ -8806,7 +8806,7 @@ getreq(struct mg_connection *conn, char *ebuf, size_t ebuf_len, int *err)
} else if (parse_http_message(
conn->buf, conn->buf_size, &conn->request_info) <= 0) {
snprintf(
ebuf, ebuf_len, "Bad request: [%.*s]", conn->data_len, conn->buf);
ebuf, ebuf_len, "Bad request: [len=%d]", conn->data_len);
*err = 400;
return 0;
} else {