1
1
mirror of https://github.com/systemd/systemd-stable.git synced 2025-01-24 02:03:54 +03:00

journal-remote: reduce scope of variable

https://github.com/systemd/systemd/pull/11953/files#r264188513
This commit is contained in:
Zbigniew Jędrzejewski-Szmek 2019-10-21 19:43:07 +02:00
parent cd8ad5965f
commit ce2f43797a

View File

@ -266,7 +266,6 @@ static int request_handler(
int r, code, fd;
_cleanup_free_ char *hostname = NULL;
bool chunked = false;
size_t len;
assert(connection);
assert(connection_cls);
@ -302,6 +301,8 @@ static int request_handler(
header = MHD_lookup_connection_value(connection, MHD_HEADER_KIND, "Content-Length");
if (header) {
size_t len;
if (chunked)
return mhd_respond(connection, MHD_HTTP_BAD_REQUEST,
"Content-Length must not specified when Transfer-Encoding type is 'chuncked'");