Skip to content

Commit 80e5c58

Browse files
committed
fix bug549211
1 parent d6c0e25 commit 80e5c58

File tree

1 file changed

+3
-9
lines changed

1 file changed

+3
-9
lines changed

Release/src/http/listener/http_linux_server.cpp

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
* =+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+
1818
*/
1919
#include "stdafx.h"
20+
#include <boost/algorithm/string/find.hpp>
2021
#include "cpprest/http_helpers.h"
2122
#include "cpprest/http_server_api.h"
2223
#include "cpprest/http_server.h"
@@ -194,19 +195,12 @@ void connection::handle_headers()
194195
// check if the client has requested we close the connection
195196
if (m_request.headers().match(U("connection"), name))
196197
{
197-
if (boost::iequals(name, U("close")))
198-
{
199-
m_close = true;
200-
}
198+
m_close = boost::iequals(name, U("close"));
201199
}
202200

203201
if (m_request.headers().match(U("transfer-encoding"), name))
204202
{
205-
// This is not quite right. See details in TFS#549211
206-
if (!boost::iequals(name, U("identity")))
207-
{
208-
m_chunked = true;
209-
}
203+
m_chunked = boost::ifind_first(name, U("chunked"));
210204
}
211205

212206
Concurrency::streams::producer_consumer_buffer<uint8_t> buf;

0 commit comments

Comments
 (0)