Commit ad516202 authored by Parthiban Balasubramanian's avatar Parthiban Balasubramanian Committed by Jens Georg
Browse files

Enforce HTTP version 1.1

Device description requests must also respond with 1.1 version same as
service description requests.

https://bugzilla.gnome.org/show_bug.cgi?id=711167
parent 0865229b
......@@ -892,6 +892,17 @@ host_path_handler (G_GNUC_UNUSED SoupServer *server,
goto DONE;
}
/* Always send HTTP 1.1 for device description requests
* Also set Connection: close header, since the request originated
* from a HTTP 1.0 client
*/
if (soup_message_get_http_version (msg) == SOUP_HTTP_1_0) {
soup_message_set_http_version (msg, SOUP_HTTP_1_1);
soup_message_headers_append (msg->response_headers,
"Connection",
"close");
}
user_agent = soup_message_headers_get_one (msg->request_headers,
"User-Agent");
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment