jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ju...@apache.org
Subject svn commit: r604592 - /jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/util/RepositoryLock.java
Date Sun, 16 Dec 2007 09:49:15 GMT
Author: jukka
Date: Sun Dec 16 01:49:15 2007
New Revision: 604592

URL: http://svn.apache.org/viewvc?rev=604592&view=rev
Log:
JCR-933: Need to intern the full identifier string, not just a part of it for the "synchronized
(identifier)" block to work as designed.

Modified:
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/util/RepositoryLock.java

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/util/RepositoryLock.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/util/RepositoryLock.java?rev=604592&r1=604591&r2=604592&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/util/RepositoryLock.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/util/RepositoryLock.java
Sun Dec 16 01:49:15 2007
@@ -97,8 +97,9 @@
         try {
             directory = new File(path).getCanonicalFile();
             file = new File(directory, LOCK);
-            identifier = RepositoryLock.class.getName()
-                + ":" + directory.getPath().intern();
+            identifier =
+                (RepositoryLock.class.getName() + ":" + directory.getPath())
+                .intern();
             lock = null;
         } catch (IOException e) {
             throw new RepositoryException(



Mime
View raw message