You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by re...@apache.org on 2007/04/28 00:00:40 UTC
svn commit: r533239 - in
/tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector:
CometEventImpl.java LocalStrings.properties
Author: remm
Date: Fri Apr 27 15:00:40 2007
New Revision: 533239
URL: http://svn.apache.org/viewvc?view=rev&rev=533239
Log:
- Add an explicit check for null (it's there in the facades ...).
Modified:
tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector/CometEventImpl.java
tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector/LocalStrings.properties
Modified: tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector/CometEventImpl.java
URL: http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector/CometEventImpl.java?view=diff&rev=533239&r1=533238&r2=533239
==============================================================================
--- tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector/CometEventImpl.java (original)
+++ tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector/CometEventImpl.java Fri Apr 27 15:00:40 2007
@@ -25,10 +25,18 @@
import javax.servlet.http.HttpServletResponse;
import org.apache.catalina.CometEvent;
+import org.apache.catalina.util.StringManager;
public class CometEventImpl implements CometEvent {
+ /**
+ * The string manager for this package.
+ */
+ protected static StringManager sm =
+ StringManager.getManager(Constants.Package);
+
+
public CometEventImpl(Request request, Response response) {
this.request = request;
this.response = response;
@@ -81,6 +89,9 @@
}
public void close() throws IOException {
+ if (request == null) {
+ throw new IllegalStateException(sm.getString("cometEvent.nullRequest"));
+ }
request.setComet(false);
response.finishResponse();
}
Modified: tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector/LocalStrings.properties
URL: http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector/LocalStrings.properties?view=diff&rev=533239&r1=533238&r2=533239
==============================================================================
--- tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector/LocalStrings.properties (original)
+++ tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector/LocalStrings.properties Fri Apr 27 15:00:40 2007
@@ -23,6 +23,7 @@
#
coyoteAdapter.service=An exception or error occurred in the container during the request processing
+coyoteAdapter.read=The servlet did not read all available bytes during the processing of the read event
#
# CoyoteResponse
@@ -48,8 +49,9 @@
coyoteRequest.attributeEvent=Exception thrown by attributes event listener
coyoteRequest.parseParameters=Exception thrown whilst processing POSTed parameters
coyoteRequest.postTooLarge=Parameters were not parsed because the size of the posted data was too big. Use the maxPostSize attribute of the connector to resolve this if the application should accept large POSTs.
-requestFacade.nullRequest=Null request object
-responseFacade.nullResponse=Null response object
+requestFacade.nullRequest=The request object has been recycled and is no longer associated with this facade
+responseFacade.nullResponse=The response object has been recycled and is no longer associated with this facade
+cometEvent.nullRequest=The event object has been recycled and is no longer associated with a request
#
# MapperListener
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org