cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r1169880 - /cxf/trunk/common/common/src/main/java/org/apache/cxf/jaxb/JAXBContextCache.java
Date Mon, 12 Sep 2011 19:19:13 GMT
Author: dkulp
Date: Mon Sep 12 19:19:13 2011
New Revision: 1169880

URL: http://svn.apache.org/viewvc?rev=1169880&view=rev
Log:
[CXF-3801] Make sure the calls into the CacheMap are fully synchronized.

Modified:
    cxf/trunk/common/common/src/main/java/org/apache/cxf/jaxb/JAXBContextCache.java

Modified: cxf/trunk/common/common/src/main/java/org/apache/cxf/jaxb/JAXBContextCache.java
URL: http://svn.apache.org/viewvc/cxf/trunk/common/common/src/main/java/org/apache/cxf/jaxb/JAXBContextCache.java?rev=1169880&r1=1169879&r2=1169880&view=diff
==============================================================================
--- cxf/trunk/common/common/src/main/java/org/apache/cxf/jaxb/JAXBContextCache.java (original)
+++ cxf/trunk/common/common/src/main/java/org/apache/cxf/jaxb/JAXBContextCache.java Mon Sep
12 19:19:13 2011
@@ -158,7 +158,9 @@ public final class JAXBContextCache {
         if (cachedContextAndSchemas != null) {
             context = cachedContextAndSchemas.getContext();
             if (context ==  null) {
-                JAXBCONTEXT_CACHE.remove(cachedContextAndSchemas.getClasses());
+                synchronized (JAXBCONTEXT_CACHE) {
+                    JAXBCONTEXT_CACHE.remove(cachedContextAndSchemas.getClasses());
+                }
                 cachedContextAndSchemas = null;
             }
         }



Mime
View raw message