jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mreut...@apache.org
Subject svn commit: r1165609 - /jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/FineGrainedISMLocking.java
Date Tue, 06 Sep 2011 11:26:33 GMT
Author: mreutegg
Date: Tue Sep  6 11:26:33 2011
New Revision: 1165609

URL: http://svn.apache.org/viewvc?rev=1165609&view=rev
Log:
JCR-3065: ConcurrentModificationException in FineGrainedISMLocking

Modified:
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/FineGrainedISMLocking.java

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/FineGrainedISMLocking.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/FineGrainedISMLocking.java?rev=1165609&r1=1165608&r2=1165609&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/FineGrainedISMLocking.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/FineGrainedISMLocking.java
Tue Sep  6 11:26:33 2011
@@ -385,9 +385,11 @@ public class FineGrainedISMLocking imple
             }
             for (int i = 0; i < slots.length; i++) {
                 Map<ItemId, Integer> locks = slots[i];
-                for (ItemId id : locks.keySet()) {
-                    if (FineGrainedISMLocking.hasDependency(changes, id)) {
-                        return true;
+                synchronized (locks) {
+                    for (ItemId id : locks.keySet()) {
+                        if (FineGrainedISMLocking.hasDependency(changes, id)) {
+                            return true;
+                        }
                     }
                 }
             }



Mime
View raw message