https://bz.apache.org/bugzilla/show_bug.cgi?id=70000

            Bug ID: 70000
           Summary: org.apache.catalina.connector.Response.getHeaderNames(
                    ) returns duplicated "Content-Length" and
                    "Content-Type"
           Product: Tomcat 10
           Version: 10.1.53
          Hardware: PC
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Catalina
          Assignee: [email protected]
          Reporter: [email protected]
  Target Milestone: ------

After the changes
https://github.com/apache/tomcat/commit/5f9bd1d87d18b3898ebcc5a103a8266f5f98ce9a
for https://bz.apache.org/bugzilla/show_bug.cgi?id=69967, the getHeaderNames
method on org.apache.catalina.connector.Response returns duplicated
"Content-Length" and "Content-Type" in this use case:
1) Call response.getOutputStream().flush(), that causes the underlying coyote
response object to commit. The committed coyote response object now has all the
headers, including "Content-Length" and "Content-Type"
2) Call response.getHeaderNames() to inspect the resulting headers. It gathers
the header names from the underlying coyote response object -- which contains
"Content-Length" and "Content-Type" -- and then adds "Content-Length" and
"Content-Type" again to the list

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to