svn commit: r516081 - /tomcat/tc6.0.x/trunk/java/org/apache/jasper/compiler/TextOptimizer.java

2007-03-08 Thread remm
Author: remm
Date: Thu Mar  8 07:52:15 2007
New Revision: 516081

URL: http://svn.apache.org/viewvc?view=rev&rev=516081
Log:
- Use the trim property and trim directive, which should be equivalent to 
Jasper's own attribute.

Modified:
tomcat/tc6.0.x/trunk/java/org/apache/jasper/compiler/TextOptimizer.java

Modified: 
tomcat/tc6.0.x/trunk/java/org/apache/jasper/compiler/TextOptimizer.java
URL: 
http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/java/org/apache/jasper/compiler/TextOptimizer.java?view=diff&rev=516081&r1=516080&r2=516081
==
--- tomcat/tc6.0.x/trunk/java/org/apache/jasper/compiler/TextOptimizer.java 
(original)
+++ tomcat/tc6.0.x/trunk/java/org/apache/jasper/compiler/TextOptimizer.java Thu 
Mar  8 07:52:15 2007
@@ -29,6 +29,7 @@
 static class TextCatVisitor extends Node.Visitor {
 
 private Options options;
+private PageInfo pageInfo;
 private int textNodeCount = 0;
 private Node.TemplateText firstTextNode = null;
 private StringBuffer textBuffer;
@@ -36,6 +37,7 @@
 
 public TextCatVisitor(Compiler compiler) {
 options = compiler.getCompilationContext().getOptions();
+pageInfo = compiler.getPageInfo();
 }
 
 public void doVisit(Node n) throws JasperException {
@@ -70,8 +72,8 @@
 }
 
 public void visit(Node.TemplateText n) throws JasperException {
-
-if (options.getTrimSpaces() && n.isAllSpace()) {
+if ((options.getTrimSpaces() || 
pageInfo.isTrimDirectiveWhitespaces()) 
+&& n.isAllSpace()) {
 n.setText(emptyText);
 return;
 }



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r516086 - /tomcat/tc6.0.x/trunk/java/org/apache/jasper/compiler/JDTCompiler.java

2007-03-08 Thread remm
Author: remm
Date: Thu Mar  8 08:02:35 2007
New Revision: 516086

URL: http://svn.apache.org/viewvc?view=rev&rev=516086
Log:
- 41790: close file stream.

Modified:
tomcat/tc6.0.x/trunk/java/org/apache/jasper/compiler/JDTCompiler.java

Modified: tomcat/tc6.0.x/trunk/java/org/apache/jasper/compiler/JDTCompiler.java
URL: 
http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/java/org/apache/jasper/compiler/JDTCompiler.java?view=diff&rev=516086&r1=516085&r2=516086
==
--- tomcat/tc6.0.x/trunk/java/org/apache/jasper/compiler/JDTCompiler.java 
(original)
+++ tomcat/tc6.0.x/trunk/java/org/apache/jasper/compiler/JDTCompiler.java Thu 
Mar  8 08:02:35 2007
@@ -99,11 +99,11 @@
 
 public char[] getContents() {
 char[] result = null;
+FileInputStream is = null;
 try {
-InputStreamReader isReader =
-new InputStreamReader(new FileInputStream(sourceFile),
-ctxt.getOptions().getJavaEncoding());
-Reader reader = new BufferedReader(isReader);
+is = new FileInputStream(sourceFile);
+Reader reader = 
+new BufferedReader(new InputStreamReader(is, 
ctxt.getOptions().getJavaEncoding()));
 if (reader != null) {
 char[] chars = new char[8192];
 StringBuffer buf = new StringBuffer();
@@ -117,6 +117,14 @@
 }
 } catch (IOException e) {
 log.error("Compilation error", e);
+} finally {
+if (is != null) {
+try {
+is.close();
+} catch (IOException exc) {
+// Ignore
+}
+}
 }
 return result;
 }



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 41790] - JDTCompiler::getContents does not close the reader

2007-03-08 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUGĀ·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED ANDĀ·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=41790


[EMAIL PROTECTED] changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution||FIXED




--- Additional Comments From [EMAIL PROTECTED]  2007-03-08 08:05 ---
Only the FileInputStream needs to be closed (the others are irrelevant).

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug, or are watching the assignee.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r516110 - /tomcat/container/tc5.5.x/webapps/docs/developers.xml

2007-03-08 Thread jim
Author: jim
Date: Thu Mar  8 09:25:14 2007
New Revision: 516110

URL: http://svn.apache.org/viewvc?view=rev&rev=516110
Log:
foo

Modified:
tomcat/container/tc5.5.x/webapps/docs/developers.xml

Modified: tomcat/container/tc5.5.x/webapps/docs/developers.xml
URL: 
http://svn.apache.org/viewvc/tomcat/container/tc5.5.x/webapps/docs/developers.xml?view=diff&rev=516110&r1=516109&r2=516110
==
--- tomcat/container/tc5.5.x/webapps/docs/developers.xml (original)
+++ tomcat/container/tc5.5.x/webapps/docs/developers.xml Thu Mar  8 09:25:14 
2007
@@ -38,6 +38,7 @@
   Jan Luehe (luehe): Jasper
   Jean-Francois Arcand (jfarcand): Catalina
   Jean-Frederic Clere (jfclere): Connectors
+  Jim Jagielski (jim): Connectors
   Kin-Man Chung (kinman): Jasper
   Mark Thomas (markt): CGI, SSI, WebDAV, bug fixing
   Mladen Turk (mturk): Connectors



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r516111 - /tomcat/tc6.0.x/trunk/webapps/docs/developers.xml

2007-03-08 Thread jim
Author: jim
Date: Thu Mar  8 09:26:05 2007
New Revision: 516111

URL: http://svn.apache.org/viewvc?view=rev&rev=516111
Log:
foo2

Modified:
tomcat/tc6.0.x/trunk/webapps/docs/developers.xml

Modified: tomcat/tc6.0.x/trunk/webapps/docs/developers.xml
URL: 
http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/webapps/docs/developers.xml?view=diff&rev=516111&r1=516110&r2=516111
==
--- tomcat/tc6.0.x/trunk/webapps/docs/developers.xml (original)
+++ tomcat/tc6.0.x/trunk/webapps/docs/developers.xml Thu Mar  8 09:26:05 2007
@@ -38,6 +38,7 @@
   Jan Luehe (luehe): Jasper
   Jean-Francois Arcand (jfarcand): Catalina
   Jean-Frederic Clere (jfclere): Connectors
+  Jim Jagielski (jim): Connectors
   Kin-Man Chung (kinman): Jasper
   Mladen Turk (mturk): Connectors
   Peter Rossbach (pero): Catalina, Clustering, JMX



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r516177 - in /tomcat/site/trunk: docs/download-55.html xdocs/download-55.xml

2007-03-08 Thread fhanik
Author: fhanik
Date: Thu Mar  8 13:17:22 2007
New Revision: 516177

URL: http://svn.apache.org/viewvc?view=rev&rev=516177
Log:
Updated download link to 5.5.23, will announce after mirror sync from 
www.apache.org/dist/tomcat/tomcat-5/v5.5.23
At the same time as the announcement, the website will be updated with the new 
download info

Modified:
tomcat/site/trunk/docs/download-55.html
tomcat/site/trunk/xdocs/download-55.xml

Modified: tomcat/site/trunk/docs/download-55.html
URL: 
http://svn.apache.org/viewvc/tomcat/site/trunk/docs/download-55.html?view=diff&rev=516177&r1=516176&r2=516177
==
--- tomcat/site/trunk/docs/download-55.html (original)
+++ tomcat/site/trunk/docs/download-55.html Thu Mar  8 13:17:22 2007
@@ -211,7 +211,7 @@
 
 
 http://www.apache.org/dist/tomcat/tomcat-5/KEYS";>KEYS |
-5.5.20 |
+5.5.23 |
 5.0.30-beta |
 5.0.28 |
 http://archive.apache.org/dist/tomcat/tomcat-5";>Archives
@@ -310,8 +310,8 @@
 
 
 
-
-5.5.20
+
+5.5.23
 
 
 
@@ -321,8 +321,8 @@
 
 
   
-  Please see the 
-  README
+  Please see the 
+  README
   file for packaging information.  It explains what every distribution 
contains.
   
 
@@ -343,19 +343,19 @@
 Core:
   
   
-  zip 
-  (http://www.apache.org/dist/tomcat/tomcat-5/v5.5.20/bin/apache-tomcat-5.5.20.zip.asc";>pgp,
 
-  http://www.apache.org/dist/tomcat/tomcat-5/v5.5.20/bin/apache-tomcat-5.5.20.zip.md5";>md5)
+  zip 
+  (http://www.apache.org/dist/tomcat/tomcat-5/v5.5.23/bin/apache-tomcat-5.5.23.zip.asc";>pgp,
 
+  http://www.apache.org/dist/tomcat/tomcat-5/v5.5.23/bin/apache-tomcat-5.5.23.zip.md5";>md5)
   
   
-  tar.gz
 
-  (http://www.apache.org/dist/tomcat/tomcat-5/v5.5.20/bin/apache-tomcat-5.5.20.tar.gz.asc";>pgp,
 
-  http://www.apache.org/dist/tomcat/tomcat-5/v5.5.20/bin/apache-tomcat-5.5.20.tar.gz.md5";>md5)
+  tar.gz
 
+  (http://www.apache.org/dist/tomcat/tomcat-5/v5.5.23/bin/apache-tomcat-5.5.23.tar.gz.asc";>pgp,
 
+  http://www.apache.org/dist/tomcat/tomcat-5/v5.5.23/bin/apache-tomcat-5.5.23.tar.gz.md5";>md5)
   
   
-  Windows 
Service Installer 
-  (http://www.apache.org/dist/tomcat/tomcat-5/v5.5.20/bin/apache-tomcat-5.5.20.exe.asc";>pgp,
 
-  http://www.apache.org/dist/tomcat/tomcat-5/v5.5.20/bin/apache-tomcat-5.5.20.exe.md5";>md5)
+  Windows 
Service Installer 
+  (http://www.apache.org/dist/tomcat/tomcat-5/v5.5.23/bin/apache-tomcat-5.5.23.exe.asc";>pgp,
 
+  http://www.apache.org/dist/tomcat/tomcat-5/v5.5.23/bin/apache-tomcat-5.5.23.exe.md5";>md5)
   
   
 
@@ -363,28 +363,28 @@
 Deployer: 
   
   
-  zip
 
-  (http://www.apache.org/dist/tomcat/tomcat-5/v5.5.20/bin/apache-tomcat-5.5.20-deployer.zip.asc";>pgp,
 
-   http://www.apache.org/dist/tomcat/tomcat-5/v5.5.20/bin/apache-tomcat-5.5.20-deployer.zip.md5";>md5)
+  zip
 
+  (http://www.apache.org/dist/tomcat/tomcat-5/v5.5.23/bin/apache-tomcat-5.5.23-deployer.zip.asc";>pgp,
 
+   http://www.apache.org/dist/tomcat/tomcat-5/v5.5.23/bin/apache-tomcat-5.5.23-deployer.zip.md5";>md5)
   
   
-  tar.gz
 
-  (http://www.apache.org/dist/tomcat/tomcat-5/v5.5.20/bin/apache-tomcat-5.5.20-deployer.tar.gz.asc";>pgp,
 
-  http://www.apache.org/dist/tomcat/tomcat-5/v5.5.20/bin/apache-tomcat-5.5.20-deployer.tar.gz.md5";>md5)
+  tar.gz
 
+  (http://www.apache.org/dist/tomcat/tomcat-5/v5.5.23/bin/apache-tomcat-5.5.23-deployer.tar.gz.asc";>pgp,
 
+  http://www.apache.org/dist/tomcat/tomcat-5/v5.5.23/bin/apache-tomcat-5.5.23-deployer.tar.gz.md5";>md5)
   
   
 
 Embedded:
   
   
-  zip
 
-  (http://www.apache.org/dist/tomcat/tomcat-5/v5.5.20/bin/apache-tomcat-5.5.20-embed.zip.asc";>pgp,
 
-  http://www.apache.org/dist/tomcat/tomcat-5/v5.5.20/bin/apache-tomcat-5.5.20-embed.zip.md5";>md5)
+  zip
 
+  (http://www.apache.org/dist/tomcat/tomcat-5/v5.5.23/bin/apache-tomcat-5.5.23-embed.zip.asc";>pgp,
 
+  http://www.apache.org/dist/tomcat/tomcat-5/v5.5.23/bin/apache-tomcat-5.5.23-embed.zip.md5";>md5)
   
   
-  tar.gz
 
-  (http://www.apache.org/dist/tomcat/tomcat-5/v5.5.20/bin/apache-tomcat-5.5.20-embed.tar.gz.asc";>pgp,
 
-  http://www.apache.org/dist/tomcat/tomcat-5/v5.5.20/bin/apache-tomcat-5.5.20-embed.tar.gz.md5";>md5)
+  tar.gz
 
+  (http://www.apache.org/dist/tomcat/tomcat-5/v5.5.23/bin/apache-tomcat-5.5.23-embed.tar.gz.asc";>pgp,
 
+  http://www.apache.org/dist/tomcat/tomcat-5/v5.5.23/bin/apache-tomcat-5.5.23-embed.tar.gz.md5";>md5)
   
 

svn commit: r516190 - /tomcat/tc6.0.x/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java

2007-03-08 Thread fhanik
Author: fhanik
Date: Thu Mar  8 13:45:11 2007
New Revision: 516190

URL: http://svn.apache.org/viewvc?view=rev&rev=516190
Log:
just added some notes

Modified:
tomcat/tc6.0.x/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java

Modified: tomcat/tc6.0.x/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java
URL: 
http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java?view=diff&rev=516190&r1=516189&r2=516190
==
--- tomcat/tc6.0.x/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java 
(original)
+++ tomcat/tc6.0.x/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java Thu 
Mar  8 13:45:11 2007
@@ -1291,11 +1291,11 @@
 KeyAttachment attachment = (KeyAttachment)sk.attachment();
 try {
 if ( sk.isValid() && attachment != null ) {
-attachment.access();
-sk.attach(attachment);
-int interestOps = sk.interestOps();
+attachment.access();//make sure we don't time out 
valid sockets
+sk.attach(attachment);//cant remember why this is 
here
+int interestOps = sk.interestOps();//get the 
interestops, in case we need to reset them
 sk.interestOps(0); //this is a must, so that we 
don't have multiple threads messing with the socket
-attachment.interestOps(0);
+attachment.interestOps(0);//fast access interestp 
ops
 NioChannel channel = attachment.getChannel();
 if (sk.isReadable() || sk.isWritable() ) {
 if ( attachment.getComet() ) {



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]