cocoon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From reinh...@apache.org
Subject svn commit: r1054829 - in /cocoon/trunk/subprojects/cocoon-jnet/src: changes/changes.xml main/java/org/apache/cocoon/jnet/DynamicURLStreamHandlerFactory.java
Date Mon, 03 Jan 2011 23:46:26 GMT
Author: reinhard
Date: Mon Jan  3 23:46:25 2011
New Revision: 1054829

URL: http://svn.apache.org/viewvc?rev=1054829&view=rev
Log:
COCOON-2277
fix potential NPE 

Modified:
    cocoon/trunk/subprojects/cocoon-jnet/src/changes/changes.xml
    cocoon/trunk/subprojects/cocoon-jnet/src/main/java/org/apache/cocoon/jnet/DynamicURLStreamHandlerFactory.java

Modified: cocoon/trunk/subprojects/cocoon-jnet/src/changes/changes.xml
URL: http://svn.apache.org/viewvc/cocoon/trunk/subprojects/cocoon-jnet/src/changes/changes.xml?rev=1054829&r1=1054828&r2=1054829&view=diff
==============================================================================
--- cocoon/trunk/subprojects/cocoon-jnet/src/changes/changes.xml (original)
+++ cocoon/trunk/subprojects/cocoon-jnet/src/changes/changes.xml Mon Jan  3 23:46:25 2011
@@ -28,6 +28,9 @@
   </properties>
   <body>
     <release version="1.2.0-SNAPSHOT" date="2009-00-00" description="unreleased">
+      <action dev="reinhard" type="update" issue="COCOON-2277">
+        Fix potential NPE in DynamicURLStreamHandlerFactory.
+      </action>
       <action dev="reinhard" type="update">
         Use Java 5 language features throughout the codebase.
       </action>

Modified: cocoon/trunk/subprojects/cocoon-jnet/src/main/java/org/apache/cocoon/jnet/DynamicURLStreamHandlerFactory.java
URL: http://svn.apache.org/viewvc/cocoon/trunk/subprojects/cocoon-jnet/src/main/java/org/apache/cocoon/jnet/DynamicURLStreamHandlerFactory.java?rev=1054829&r1=1054828&r2=1054829&view=diff
==============================================================================
--- cocoon/trunk/subprojects/cocoon-jnet/src/main/java/org/apache/cocoon/jnet/DynamicURLStreamHandlerFactory.java
(original)
+++ cocoon/trunk/subprojects/cocoon-jnet/src/main/java/org/apache/cocoon/jnet/DynamicURLStreamHandlerFactory.java
Mon Jan  3 23:46:25 2011
@@ -18,6 +18,7 @@ package org.apache.cocoon.jnet;
 
 import java.net.URLStreamHandler;
 import java.net.URLStreamHandlerFactory;
+import java.util.Collections;
 import java.util.Iterator;
 import java.util.LinkedList;
 import java.util.List;
@@ -38,7 +39,7 @@ public class DynamicURLStreamHandlerFact
         List<URLStreamHandlerFactory> list = FACTORIES.get();
 
         if (list == null) {
-            list = new LinkedList<URLStreamHandlerFactory>();
+            list = Collections.synchronizedList(new LinkedList<URLStreamHandlerFactory>());
             FACTORIES.set(list);
         }
 



Mime
View raw message