Commit 621aa30b authored by Zeeshan Ali (Khattak)'s avatar Zeeshan Ali (Khattak)
Browse files

Check for body length rather than Content-Length

soup_message_headers_get_content_length() only returns non-0 if the
encoding in use is 'Content-Length'. Although I'm not sure we are
correctly handling 'chunked' encoding but at least now we pass the DLNA
CTT test
parent d65d509b
......@@ -874,7 +874,6 @@ control_server_handler (SoupServer *server,
char *action_name;
char *end;
GUPnPServiceAction *action;
goffset length;
service = GUPNP_SERVICE (user_data);
......@@ -884,8 +883,7 @@ control_server_handler (SoupServer *server,
length = soup_message_headers_get_content_length (msg->request_headers);
if (length == 0) {
if (msg->request_body->length == 0) {
soup_message_set_status (msg, SOUP_STATUS_BAD_REQUEST);
Supports Markdown
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