w1ida opened a new pull request, #676:
URL: https://github.com/apache/tomcat/pull/676

   Summary:
   This commit fixes a bug in the code related to handling chunked transfer 
encoding. The original code only handled chunked transfer encoding when http11 
was true, entityBody was true, and connectionClosePresent was false. However, 
this did not take into account the case where the request headers indicated 
chunked transfer encoding.
   
   The modified code now includes a check for isChunked(headers) in addition to 
the existing conditions. This ensures that chunked transfer encoding is 
correctly handled when all the specified conditions are met, as well as when 
the request headers indicate chunked transfer encoding.
   
   Detailed Explanation:
   
   The original code snippet did not consider the situation where the request 
headers explicitly specified chunked transfer encoding. This resulted in a bug 
where chunked transfer encoding was not handled correctly.
   example: 
   
javax.servlet.http.HttpServletResponse#setHeader("Transfer-encoding","chunked");
   javax.servlet.http.HttpServletResponse#setHeader("Connection","close");
   
   The modification addresses this issue by introducing a call to 
isChunked(headers) as an additional condition. This ensures that chunked 
transfer encoding is handled correctly when all the conditions (http11, 
entityBody, connectionClosePresent) are met, or when the request headers 
indicate chunked transfer encoding.
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org

Reply via email to