Fixes #638 - ConnectHandler responses should have Content-Length.

Added Content-Length: 0 to the responses.
This commit is contained in:
Simone Bordet 2016-06-13 17:54:41 +02:00
parent b9a27f792a
commit 2b539b6383
1 changed files with 1 additions and 0 deletions

View File

@ -362,6 +362,7 @@ public class ConnectHandler extends HandlerWrapper
try
{
response.setStatus(statusCode);
response.setContentLength(0);
if (statusCode != HttpServletResponse.SC_OK)
response.setHeader(HttpHeader.CONNECTION.asString(), HttpHeaderValue.CLOSE.asString());
response.getOutputStream().close();