jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ste...@apache.org
Subject svn commit: r783719 - /jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/NodeTypeManagerImpl.java
Date Thu, 11 Jun 2009 10:36:59 GMT
Author: stefan
Date: Thu Jun 11 10:36:59 2009
New Revision: 783719

URL: http://svn.apache.org/viewvc?rev=783719&view=rev
Log:
JCR-2139: Registering NodeType with defaultvalues fails with IndexOutOfBounds

Modified:
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/NodeTypeManagerImpl.java

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/NodeTypeManagerImpl.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/NodeTypeManagerImpl.java?rev=783719&r1=783718&r2=783719&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/NodeTypeManagerImpl.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/NodeTypeManagerImpl.java
Thu Jun 11 10:36:59 2009
@@ -773,7 +773,7 @@
                     ValueConstraint[] qconstraints = new ValueConstraint[constraints.length];
                     for (int j = 0; j < constraints.length; j++) {
                         try {
-                            qconstraints[j] = ValueConstraint.create(type, constraints[i],
session);
+                            qconstraints[j] = ValueConstraint.create(type, constraints[j],
session);
                         } catch (InvalidConstraintException e) {
                             throw new InvalidNodeTypeDefinitionException(
                                     "Invalid value constraint " + constraints[i], e);
@@ -787,7 +787,7 @@
                     InternalValue[] qvalues = new InternalValue[values.length];
                     for (int j = 0; j < values.length; j++) {
                         try {
-                            qvalues[j] = InternalValue.create(values[i], session);
+                            qvalues[j] = InternalValue.create(values[j], session);
                         } catch (ValueFormatException e) {
                             throw new InvalidNodeTypeDefinitionException(
                                     "Invalid default value format", e);



Mime
View raw message