tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ma...@apache.org
Subject svn commit: r1044858 - /tomcat/trunk/java/org/apache/catalina/session/ManagerBase.java
Date Sun, 12 Dec 2010 17:24:47 GMT
Author: markt
Date: Sun Dec 12 17:24:47 2010
New Revision: 1044858

URL: http://svn.apache.org/viewvc?rev=1044858&view=rev
Log:
Fix FindBugs issues in this class

Modified:
    tomcat/trunk/java/org/apache/catalina/session/ManagerBase.java

Modified: tomcat/trunk/java/org/apache/catalina/session/ManagerBase.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/session/ManagerBase.java?rev=1044858&r1=1044857&r2=1044858&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/catalina/session/ManagerBase.java (original)
+++ tomcat/trunk/java/org/apache/catalina/session/ManagerBase.java Sun Dec 12 17:24:47 2010
@@ -1026,8 +1026,8 @@ public abstract class ManagerBase extend
         int oldMaxActiveSessions = this.maxActiveSessions;
         this.maxActiveSessions = max;
         support.firePropertyChange("maxActiveSessions",
-                                   new Integer(oldMaxActiveSessions),
-                                   new Integer(this.maxActiveSessions));
+                                   Integer.valueOf(oldMaxActiveSessions),
+                                   Integer.valueOf(this.maxActiveSessions));
 
     }
 
@@ -1147,7 +1147,7 @@ public abstract class ManagerBase extend
         }
         if (counter > 0) {
             if (oldest < now) {
-                result = (int) ((1000*60*counter)/(now - oldest));
+                result = (1000*60*counter)/(int) (now - oldest);
             } else {
                 result = Integer.MAX_VALUE;
             }
@@ -1190,7 +1190,7 @@ public abstract class ManagerBase extend
         }
         if (counter > 0) {
             if (oldest < now) {
-                result = (int) ((1000*60*counter)/(now - oldest));
+                result = (1000*60*counter)/(int) (now - oldest);
             } else {
                 // Better than reporting zero
                 result = Integer.MAX_VALUE;



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


Mime
View raw message