tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ma...@apache.org
Subject svn commit: r1142430 - in /tomcat/trunk: java/org/apache/catalina/valves/CrawlerSessionManagerValve.java webapps/docs/changelog.xml
Date Sun, 03 Jul 2011 13:15:58 GMT
Author: markt
Date: Sun Jul  3 13:15:58 2011
New Revision: 1142430

URL: http://svn.apache.org/viewvc?rev=1142430&view=rev
Log:
Fix possible NPE

Modified:
    tomcat/trunk/java/org/apache/catalina/valves/CrawlerSessionManagerValve.java
    tomcat/trunk/webapps/docs/changelog.xml

Modified: tomcat/trunk/java/org/apache/catalina/valves/CrawlerSessionManagerValve.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/valves/CrawlerSessionManagerValve.java?rev=1142430&r1=1142429&r2=1142430&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/catalina/valves/CrawlerSessionManagerValve.java (original)
+++ tomcat/trunk/java/org/apache/catalina/valves/CrawlerSessionManagerValve.java Sun Jul 
3 13:15:58 2011
@@ -27,6 +27,7 @@ import javax.servlet.http.HttpSession;
 import javax.servlet.http.HttpSessionBindingEvent;
 import javax.servlet.http.HttpSessionBindingListener;
 
+import org.apache.catalina.LifecycleException;
 import org.apache.catalina.connector.Request;
 import org.apache.catalina.connector.Response;
 import org.apache.juli.logging.Log;
@@ -114,6 +115,14 @@ public class CrawlerSessionManagerValve 
 
 
     @Override
+    protected void initInternal() throws LifecycleException {
+        super.initInternal();
+        
+        uaPattern = Pattern.compile(crawlerUserAgents);
+    }
+
+
+    @Override
     public void invoke(Request request, Response response) throws IOException,
             ServletException {
 

Modified: tomcat/trunk/webapps/docs/changelog.xml
URL: http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/changelog.xml?rev=1142430&r1=1142429&r2=1142430&view=diff
==============================================================================
--- tomcat/trunk/webapps/docs/changelog.xml (original)
+++ tomcat/trunk/webapps/docs/changelog.xml Sun Jul  3 13:15:58 2011
@@ -54,6 +54,15 @@
   issues to not "pop up" wrt. others).
 -->
 <section name="Tomcat 7.0.18 (markt)">
+  <subsection name="Catalina">
+    <changelog>
+      <fix>
+        Correct regression introduced in 7.0.17 that triggered an NPE if a
+        CrawlerSessionManagerValve was used without setting crawlerUserAgents.
+        (markt)
+      </fix>
+    </changelog>
+  </subsection>
   <subsection name="Other">
     <changelog>
       <fix>



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


Mime
View raw message