Perfect response error hints

Signed-off-by: Jianhui Zhao <jianhuizhao329@gmail.com>
main
Jianhui Zhao 2017-12-30 11:05:31 +08:00
parent 34bbc9264f
commit 278f7a19dd
1 changed files with 1 additions and 1 deletions

View File

@ -330,7 +330,7 @@ static void client_parse_header(struct uh_client *cl, char *data)
if (!strcmp(data, "content-length")) {
r->content_length = strtoul(val, &err, 0);
if (err && *err) {
cl->send_error(cl, 400, "Bad Request", NULL);
cl->send_error(cl, 400, "Bad Request", "Invalid Content-Length");
return;
}
} else if (!strcmp(data, "transfer-encoding") && !strcmp(val, "chunked")) {