You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by pa...@apache.org on 2014/05/19 09:44:49 UTC
git commit: WICKET-5595: copy list of resources,
because it is modified inside the loop
Repository: wicket
Updated Branches:
refs/heads/wicket-6.x c6f92f173 -> d3fb459a0
WICKET-5595: copy list of resources, because it is modified inside the loop
Project: http://git-wip-us.apache.org/repos/asf/wicket/repo
Commit: http://git-wip-us.apache.org/repos/asf/wicket/commit/d3fb459a
Tree: http://git-wip-us.apache.org/repos/asf/wicket/tree/d3fb459a
Diff: http://git-wip-us.apache.org/repos/asf/wicket/diff/d3fb459a
Branch: refs/heads/wicket-6.x
Commit: d3fb459a0409efd526f93f9d43db8958c57ef163
Parents: c6f92f1
Author: Emond Papegaaij <em...@topicus.nl>
Authored: Mon May 19 09:43:21 2014 +0200
Committer: Emond Papegaaij <em...@topicus.nl>
Committed: Mon May 19 09:44:01 2014 +0200
----------------------------------------------------------------------
.../src/main/java/org/apache/wicket/atmosphere/EventBus.java | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/wicket/blob/d3fb459a/wicket-experimental/wicket-atmosphere/src/main/java/org/apache/wicket/atmosphere/EventBus.java
----------------------------------------------------------------------
diff --git a/wicket-experimental/wicket-atmosphere/src/main/java/org/apache/wicket/atmosphere/EventBus.java b/wicket-experimental/wicket-atmosphere/src/main/java/org/apache/wicket/atmosphere/EventBus.java
index d13965e..7790f83 100644
--- a/wicket-experimental/wicket-atmosphere/src/main/java/org/apache/wicket/atmosphere/EventBus.java
+++ b/wicket-experimental/wicket-atmosphere/src/main/java/org/apache/wicket/atmosphere/EventBus.java
@@ -50,6 +50,7 @@ import org.slf4j.LoggerFactory;
import com.google.common.collect.Collections2;
import com.google.common.collect.HashMultimap;
+import com.google.common.collect.ImmutableList;
import com.google.common.collect.Maps;
import com.google.common.collect.Multimap;
@@ -363,7 +364,7 @@ public class EventBus implements UnboundListener
ThreadContext oldContext = ThreadContext.get(false);
try
{
- for (AtmosphereResource resource : broadcaster.getAtmosphereResources())
+ for (AtmosphereResource resource : ImmutableList.copyOf(broadcaster.getAtmosphereResources()))
{
postToSingleResource(event, resource);
}