Am 2013-05-15 16:35, schrieb Christopher Schultz:
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Micheal,

On 5/15/13 3:46 AM, Michael-O wrote:
I have modified the ErrorReportValve's messages outside of the
one-byte range and the output got mangled. The response does not
contain a char encoding anymore.

Can you be more specific? What exactly did you modify, and how did you
modify it? What are the exact HTTP response headers that you get?

I know that the error valve does this:

response.setContentType("text/html");
response.setCharacterEncoding("utf-8");

but the setCharEnc method is completely ignored. Because the var
usingWriter is already set to true. This happens in the
ApplicationDispatcher#doForward line 393/394 when a servlet
performs a forward.

Looking at Tomcat 6.0.x/trunk line 393 is part of the cleanup code,
and the response PrintWriter is immediately closed. That does not
appear to have changed since 6.0.35. At this point, the request should
be /over/.

What else is going on? Is any content being generated before the
ErrorReportValve gets invoked? If the response has already been
committed, then Tomcat can't re-write the response headers.

Though a response.getReporter() is used but this one is completely
unaware of the char encoding.

I am on Tomcat 6.0.35.

Where is response.getReporter being called?

I presume this to be a bug. Should I file a BZ issue?

Hi Christopher,

did you get any chance to check my reply from 2013-05-15 17:13+02:00?
Hopefully, that mail made the issue clearer.

Thanks,

Michael


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

Reply via email to