Author: markt Date: Mon Jan 28 11:32:26 2013 New Revision: 1439351 URL: http://svn.apache.org/viewvc?rev=1439351&view=rev Log: Same ends, different means.
Modified: tomcat/trunk/test/org/apache/tomcat/websocket/TestWsWebSocketContainer.java Modified: tomcat/trunk/test/org/apache/tomcat/websocket/TestWsWebSocketContainer.java URL: http://svn.apache.org/viewvc/tomcat/trunk/test/org/apache/tomcat/websocket/TestWsWebSocketContainer.java?rev=1439351&r1=1439350&r2=1439351&view=diff ============================================================================== --- tomcat/trunk/test/org/apache/tomcat/websocket/TestWsWebSocketContainer.java (original) +++ tomcat/trunk/test/org/apache/tomcat/websocket/TestWsWebSocketContainer.java Mon Jan 28 11:32:26 2013 @@ -19,9 +19,8 @@ package org.apache.tomcat.websocket; import java.io.IOException; import java.net.URI; import java.nio.ByteBuffer; -import java.util.ArrayList; -import java.util.Collections; import java.util.List; +import java.util.concurrent.CopyOnWriteArrayList; import java.util.concurrent.CountDownLatch; import java.util.concurrent.TimeUnit; @@ -246,8 +245,7 @@ public class TestWsWebSocketContainer ex private final CountDownLatch latch; - private final List<T> messages = Collections - .synchronizedList(new ArrayList<T>()); + private final List<T> messages = new CopyOnWriteArrayList<>(); public TesterMessageHandler(CountDownLatch latch) { this.latch = latch; --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org