summaryrefslogtreecommitdiffstats
path: root/src/com/vaadin
diff options
context:
space:
mode:
authorHenri Sara <henri.sara@itmill.com>2010-06-03 06:14:24 +0000
committerHenri Sara <henri.sara@itmill.com>2010-06-03 06:14:24 +0000
commit9030085c8f82a9216662f42c3e3ddf90b9f48bc6 (patch)
tree99cdbac4596c74e74a4074d9971c30ebb724590d /src/com/vaadin
parent86a2d8c526bd9c3c44aed9739c0bb32e602624f0 (diff)
downloadvaadin-framework-9030085c8f82a9216662f42c3e3ddf90b9f48bc6.tar.gz
vaadin-framework-9030085c8f82a9216662f42c3e3ddf90b9f48bc6.zip
#5127 transaction listener must not be null
svn changeset:13514/svn branch:6.3
Diffstat (limited to 'src/com/vaadin')
-rw-r--r--src/com/vaadin/service/ApplicationContext.java1
-rw-r--r--src/com/vaadin/terminal/gwt/server/AbstractWebApplicationContext.java38
2 files changed, 21 insertions, 18 deletions
diff --git a/src/com/vaadin/service/ApplicationContext.java b/src/com/vaadin/service/ApplicationContext.java
index 244e3d1bdf..76685cc215 100644
--- a/src/com/vaadin/service/ApplicationContext.java
+++ b/src/com/vaadin/service/ApplicationContext.java
@@ -54,6 +54,7 @@ public interface ApplicationContext extends Serializable {
* called before and after each each request related to this session except
* when serving static resources.
*
+ * The transaction listener must not be null.
*
* @see com.vaadin.service.ApplicationContext#addTransactionListener(com.vaadin.service.ApplicationContext.TransactionListener)
*/
diff --git a/src/com/vaadin/terminal/gwt/server/AbstractWebApplicationContext.java b/src/com/vaadin/terminal/gwt/server/AbstractWebApplicationContext.java
index bcac87e6ad..92488ef9ca 100644
--- a/src/com/vaadin/terminal/gwt/server/AbstractWebApplicationContext.java
+++ b/src/com/vaadin/terminal/gwt/server/AbstractWebApplicationContext.java
@@ -3,22 +3,22 @@
*/
package com.vaadin.terminal.gwt.server;
-import java.io.PrintWriter;
-import java.io.Serializable;
-import java.io.StringWriter;
-import java.net.URL;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.LinkedList;
-
-import javax.servlet.http.HttpSessionBindingEvent;
-import javax.servlet.http.HttpSessionBindingListener;
-
-import com.vaadin.Application;
-import com.vaadin.service.ApplicationContext;
-import com.vaadin.terminal.ApplicationResource;
+import java.io.PrintWriter;
+import java.io.Serializable;
+import java.io.StringWriter;
+import java.net.URL;
+import java.util.Collection;
+import java.util.Collections;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.LinkedList;
+
+import javax.servlet.http.HttpSessionBindingEvent;
+import javax.servlet.http.HttpSessionBindingListener;
+
+import com.vaadin.Application;
+import com.vaadin.service.ApplicationContext;
+import com.vaadin.terminal.ApplicationResource;
/**
* Base class for web application contexts (including portlet contexts) that
@@ -36,8 +36,10 @@ public abstract class AbstractWebApplicationContext implements
protected HashMap<Application, AbstractCommunicationManager> applicationToAjaxAppMgrMap = new HashMap<Application, AbstractCommunicationManager>();
- public void addTransactionListener(TransactionListener listener) {
- listeners.add(listener);
+ public void addTransactionListener(TransactionListener listener) {
+ if (listener != null) {
+ listeners.add(listener);
+ }
}
public void removeTransactionListener(TransactionListener listener) {