summaryrefslogtreecommitdiff
path: root/libsoup/soup-message-headers.c
diff options
context:
space:
mode:
authorThomas Bluemel <tbluemel@control4.com>2019-06-27 11:33:35 -0600
committerNormen Bolling <normen.bolling@web.de>2019-08-22 07:54:38 +0000
commita1148a0431079e4ae6b7a91e135a6aca6878014d (patch)
tree27f7e8f1d5480e61758b4502a737f7ed8079f91c /libsoup/soup-message-headers.c
parentf0d2af22dc83f07cf645b4dae06e8121fd29dc1d (diff)
downloadlibsoup-a1148a0431079e4ae6b7a91e135a6aca6878014d.tar.gz
Handle response header Transfer-Encoding: identity
Don't set the encoding to SOUP_ENCODING_UNRECOGNIZED if the Transfer-Encoding value is "identity". This allows soup_message_headers_get_encoding to determine the encoding based on the other headers present (if any). Fixes #148
Diffstat (limited to 'libsoup/soup-message-headers.c')
-rw-r--r--libsoup/soup-message-headers.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libsoup/soup-message-headers.c b/libsoup/soup-message-headers.c
index cdd4f1cf..4e41b031 100644
--- a/libsoup/soup-message-headers.c
+++ b/libsoup/soup-message-headers.c
@@ -666,7 +666,7 @@ transfer_encoding_setter (SoupMessageHeaders *hdrs, const char *value)
if (value) {
if (g_ascii_strcasecmp (value, "chunked") == 0)
hdrs->encoding = SOUP_ENCODING_CHUNKED;
- else
+ else if (g_ascii_strcasecmp (value, "identity") != 0)
hdrs->encoding = SOUP_ENCODING_UNRECOGNIZED;
} else
hdrs->encoding = -1;