tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ma...@apache.org
Subject svn commit: r709821 - /tomcat/trunk/java/org/apache/catalina/connector/CoyoteWriter.java
Date Sun, 02 Nov 2008 00:48:29 GMT
Author: markt
Date: Sat Nov  1 17:48:28 2008
New Revision: 709821

URL: http://svn.apache.org/viewvc?rev=709821&view=rev
Log:
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.

Modified:
    tomcat/trunk/java/org/apache/catalina/connector/CoyoteWriter.java

Modified: tomcat/trunk/java/org/apache/catalina/connector/CoyoteWriter.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/connector/CoyoteWriter.java?rev=709821&r1=709820&r2=709821&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/catalina/connector/CoyoteWriter.java (original)
+++ tomcat/trunk/java/org/apache/catalina/connector/CoyoteWriter.java Sat Nov  1 17:48:28
2008
@@ -32,8 +32,10 @@
 
     // -------------------------------------------------------------- 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



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


Mime
View raw message