tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From fha...@apache.org
Subject svn commit: r627689 - /tomcat/trunk/java/org/apache/catalina/session/ManagerBase.java
Date Thu, 14 Feb 2008 09:55:35 GMT
Author: fhanik
Date: Thu Feb 14 01:55:23 2008
New Revision: 627689

URL: http://svn.apache.org/viewvc?rev=627689&view=rev
Log:
fix NPE
java.lang.NullPointerException at org.apache.catalina.session.ManagerBase.processExpires(ManagerBase.java:682)
        at org.apache.catalina.session.ManagerBase.backgroundProcess(ManagerBase.java:667)
        at org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1316)
        at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1601)
        at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1610)
        at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1610)
        at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1590)
        at java.lang.Thread.run(Thread.java:619)

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=627689&r1=627688&r2=627689&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/catalina/session/ManagerBase.java (original)
+++ tomcat/trunk/java/org/apache/catalina/session/ManagerBase.java Thu Feb 14 01:55:23 2008
@@ -679,7 +679,7 @@
         if(log.isDebugEnabled())
             log.debug("Start expire sessions " + getName() + " at " + timeNow + " sessioncount
" + sessions.length);
         for (int i = 0; i < sessions.length; i++) {
-            if (!sessions[i].isValid()) {
+            if (sessions[i]!=null && !sessions[i].isValid()) {
                 expireHere++;
             }
         }



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


Mime
View raw message