jackrabbit-oak-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From thom...@apache.org
Subject svn commit: r1375030 - /jackrabbit/oak/trunk/oak-jcr/src/main/java/org/apache/jackrabbit/oak/jcr/SessionImpl.java
Date Mon, 20 Aug 2012 14:01:55 GMT
Author: thomasm
Date: Mon Aug 20 14:01:55 2012
New Revision: 1375030

URL: http://svn.apache.org/viewvc?rev=1375030&view=rev
Log:
OAK-260 Avoid the "Turkish Locale Problem"

Modified:
    jackrabbit/oak/trunk/oak-jcr/src/main/java/org/apache/jackrabbit/oak/jcr/SessionImpl.java

Modified: jackrabbit/oak/trunk/oak-jcr/src/main/java/org/apache/jackrabbit/oak/jcr/SessionImpl.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-jcr/src/main/java/org/apache/jackrabbit/oak/jcr/SessionImpl.java?rev=1375030&r1=1375029&r2=1375030&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-jcr/src/main/java/org/apache/jackrabbit/oak/jcr/SessionImpl.java
(original)
+++ jackrabbit/oak/trunk/oak-jcr/src/main/java/org/apache/jackrabbit/oak/jcr/SessionImpl.java
Mon Aug 20 14:01:55 2012
@@ -19,6 +19,7 @@ package org.apache.jackrabbit.oak.jcr;
 import java.security.AccessControlException;
 import java.util.HashMap;
 import java.util.HashSet;
+import java.util.Locale;
 import java.util.Map;
 import java.util.Set;
 import javax.annotation.Nonnull;
@@ -402,7 +403,7 @@ public class SessionImpl extends Abstrac
         throw new UnsupportedRepositoryOperationException("Retention Management is not supported.");
     }
 
-    //--------------------------------------------------< Namespaces >---   
+    //--------------------------------------------------< Namespaces >---
 
     // The code below is copied from JCR Commons AbstractSession, but provides information
     // the "hasRemappings" information
@@ -428,7 +429,7 @@ public class SessionImpl extends Abstrac
         } else if (uri.length() == 0) {
             throw new NamespaceException(
                     "Default namespace is reserved and can not be remapped");
-        } else if (prefix.toLowerCase().startsWith("xml")) {
+        } else if (prefix.toLowerCase(Locale.ENGLISH).startsWith("xml")) {
             throw new NamespaceException(
                     "XML prefixes are reserved: " + prefix);
         } else if (!XMLChar.isValidNCName(prefix)) {



Mime
View raw message