From: markt Date: Sun, 2 Nov 2008 00:48:28 +0000 (+0000) Subject: Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=46051 X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=2f4e07bac0236fe45832644a7d936911310db7ca;p=tomcat7.0 Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=46051 The PrintWriter interface requires that the line separator is platform dependant. Not that this makes much sense for a web application but there is a spec so we shoud stick to it. git-svn-id: https://svn.apache.org/repos/asf/tomcat/trunk@709821 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/java/org/apache/catalina/connector/CoyoteWriter.java b/java/org/apache/catalina/connector/CoyoteWriter.java index 513f2fb21..389d8e4ac 100644 --- a/java/org/apache/catalina/connector/CoyoteWriter.java +++ b/java/org/apache/catalina/connector/CoyoteWriter.java @@ -32,8 +32,10 @@ public class CoyoteWriter // -------------------------------------------------------------- Constants - - private static final char[] LINE_SEP = { '\r', '\n' }; + // No need for a do privileged block - every web app has permission to read + // this by default + private static final char[] LINE_SEP = + System.getProperty("line.separator").toCharArray(); // ----------------------------------------------------- Instance Variables