tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From violet...@apache.org
Subject svn commit: r1717385 - in /tomcat/trunk: java/org/apache/catalina/servlets/ java/org/apache/catalina/valves/rewrite/ test/org/apache/catalina/connector/ webapps/examples/WEB-INF/classes/async/
Date Tue, 01 Dec 2015 07:54:50 GMT
Author: violetagg
Date: Tue Dec  1 07:54:50 2015
New Revision: 1717385

URL: http://svn.apache.org/viewvc?rev=1717385&view=rev
Log:
Follow up to r1717311

Modified:
    tomcat/trunk/java/org/apache/catalina/servlets/DefaultServlet.java
    tomcat/trunk/java/org/apache/catalina/valves/rewrite/RewriteValve.java
    tomcat/trunk/test/org/apache/catalina/connector/TestSendFile.java
    tomcat/trunk/webapps/examples/WEB-INF/classes/async/Async0.java

Modified: tomcat/trunk/java/org/apache/catalina/servlets/DefaultServlet.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/servlets/DefaultServlet.java?rev=1717385&r1=1717384&r2=1717385&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/catalina/servlets/DefaultServlet.java (original)
+++ tomcat/trunk/java/org/apache/catalina/servlets/DefaultServlet.java Tue Dec  1 07:54:50
2015
@@ -1718,7 +1718,7 @@ public class DefaultServlet extends Http
             && resource.isFile()
             && length > sendfileSize
             && (resource.getCanonicalPath() != null)
-            && (Boolean.TRUE == request.getAttribute(Globals.SENDFILE_SUPPORTED_ATTR))
+            && (Boolean.TRUE.equals(request.getAttribute(Globals.SENDFILE_SUPPORTED_ATTR)))
             && (request.getClass().getName().equals("org.apache.catalina.connector.RequestFacade"))
             && (response.getClass().getName().equals("org.apache.catalina.connector.ResponseFacade")))
{
             request.setAttribute(Globals.SENDFILE_FILENAME_ATTR, resource.getCanonicalPath());

Modified: tomcat/trunk/java/org/apache/catalina/valves/rewrite/RewriteValve.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/valves/rewrite/RewriteValve.java?rev=1717385&r1=1717384&r2=1717385&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/catalina/valves/rewrite/RewriteValve.java (original)
+++ tomcat/trunk/java/org/apache/catalina/valves/rewrite/RewriteValve.java Tue Dec  1 07:54:50
2015
@@ -263,7 +263,7 @@ public class RewriteValve extends ValveB
             return;
         }
 
-        if (invoked.get() == Boolean.TRUE) {
+        if (Boolean.TRUE.equals(invoked.get())) {
             try {
                 getNext().invoke(request, response);
             } finally {

Modified: tomcat/trunk/test/org/apache/catalina/connector/TestSendFile.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/test/org/apache/catalina/connector/TestSendFile.java?rev=1717385&r1=1717384&r2=1717385&view=diff
==============================================================================
--- tomcat/trunk/test/org/apache/catalina/connector/TestSendFile.java (original)
+++ tomcat/trunk/test/org/apache/catalina/connector/TestSendFile.java Tue Dec  1 07:54:50
2015
@@ -123,7 +123,7 @@ public class TestSendFile extends Tomcat
             resp.setContentType("'application/octet-stream");
             resp.setCharacterEncoding("ISO-8859-1");
             resp.setContentLengthLong(f.length());
-            if (req.getAttribute(Globals.SENDFILE_SUPPORTED_ATTR) == Boolean.TRUE) {
+            if (Boolean.TRUE.equals(req.getAttribute(Globals.SENDFILE_SUPPORTED_ATTR))) {
                 req.setAttribute(Globals.SENDFILE_FILENAME_ATTR, f.getAbsolutePath());
                 req.setAttribute(Globals.SENDFILE_FILE_START_ATTR, new Long(0));
                 req.setAttribute(Globals.SENDFILE_FILE_END_ATTR, new Long(f.length()));

Modified: tomcat/trunk/webapps/examples/WEB-INF/classes/async/Async0.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/webapps/examples/WEB-INF/classes/async/Async0.java?rev=1717385&r1=1717384&r2=1717385&view=diff
==============================================================================
--- tomcat/trunk/webapps/examples/WEB-INF/classes/async/Async0.java (original)
+++ tomcat/trunk/webapps/examples/WEB-INF/classes/async/Async0.java Tue Dec  1 07:54:50 2015
@@ -37,7 +37,7 @@ public class Async0 extends HttpServlet
 
     @Override
     protected void service(final HttpServletRequest req, final HttpServletResponse resp)
throws ServletException, IOException {
-        if (Boolean.TRUE == req.getAttribute("dispatch")) {
+        if (Boolean.TRUE.equals(req.getAttribute("dispatch"))) {
             log.info("Received dispatch, completing on the worker thread.");
             log.info("After complete called started:"+req.isAsyncStarted());
             Date date = new Date(System.currentTimeMillis());



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


Mime
View raw message