Am 2019-11-13 um 17:41 schrieb Christopher Schultz:
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Michael,

On 11/8/19 17:49, micha...@apache.org wrote:
This is an automated email from the ASF dual-hosted git
repository.

michaelo pushed a commit to branch master in repository
https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/master by this
push: new 69602cb  BZ 63905: Clean up Tomcat CSS 69602cb is
described below

commit 69602cb1ef0dc3aa2188a1b3be9fa3a1440cd1b1 Author: Michael
Osipov <micha...@apache.org> AuthorDate: Thu Nov 7 22:21:27 2019
+0100

BZ 63905: Clean up Tomcat CSS

Remove duplication in Tomcat CSS and align its usage which applies
to ErrorReportValve, and several servlets. Also update update
incorrect documentation as well. ---
java/org/apache/catalina/servlets/DefaultServlet.java | 16
++++++++++------ java/org/apache/catalina/util/TomcatCSS.java
| 16 +++++++--------- webapps/docs/changelog.xml
|  3 +++ webapps/docs/config/valve.xml                         |  5
++--- 4 files changed, 22 insertions(+), 18 deletions(-)

diff --git a/java/org/apache/catalina/servlets/DefaultServlet.java
b/java/org/apache/catalina/servlets/DefaultServlet.java index
c217cf6..2883f5c 100644 ---
a/java/org/apache/catalina/servlets/DefaultServlet.java +++
b/java/org/apache/catalina/servlets/DefaultServlet.java @@ -1815,14
+1815,18 @@ public class DefaultServlet extends HttpServlet {
String rewrittenContextPath =  rewriteUrl(contextPath);

// Render the page header -        sb.append("<html>\r\n"); +
sb.append("<!doctype html><html>\r\n"); +        /* TODO Activate
this as soon as we use smClient with the request locales +
sb.append("<!doctype html><html lang=\""); +
sb.append(smClient.getLocale().getLanguage()).append("\">\r\n"); +
*/

Thank you for this. Even though it's not yet active, It's good to have
it in there as a reminder for the future.

Do you think it's worth having any \r\n characters in here? Seems like
just a waste of space on the wire.

I would consider two options:

* Remove line breaks, the browser does not need that
* Use a StringWriter/PrintWriter to produce consistent line breaks on the platforms Tomcat runs

Michael

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

Reply via email to