tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From funk...@apache.org
Subject svn commit: r809603 - /tomcat/trunk/java/org/apache/catalina/manager/ManagerServlet.java
Date Mon, 31 Aug 2009 14:17:38 GMT
Author: funkman
Date: Mon Aug 31 14:17:37 2009
New Revision: 809603

URL: http://svn.apache.org/viewvc?rev=809603&view=rev
Log:
https://issues.apache.org/bugzilla/show_bug.cgi?id=47705

ArithmeticException: / by zero when expiring sessions via manager 


Modified:
    tomcat/trunk/java/org/apache/catalina/manager/ManagerServlet.java

Modified: tomcat/trunk/java/org/apache/catalina/manager/ManagerServlet.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/manager/ManagerServlet.java?rev=809603&r1=809602&r2=809603&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/catalina/manager/ManagerServlet.java (original)
+++ tomcat/trunk/java/org/apache/catalina/manager/ManagerServlet.java Mon Aug 31 14:17:37
2009
@@ -1106,6 +1106,8 @@
             int histoInterval = maxInactiveInterval / maxCount;
             if ( histoInterval * maxCount < maxInactiveInterval ) 
                 histoInterval++;
+            if (0==histoInterval)
+                histoInterval=1;
             maxCount = maxInactiveInterval / histoInterval;
             if ( histoInterval * maxCount < maxInactiveInterval ) 
                 maxCount++;



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


Mime
View raw message