jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From fmesc...@apache.org
Subject svn commit: r575640 - /jackrabbit/trunk/contrib/jackrabbit-jcr-mapping/jcr-mapping/src/main/java/org/apache/jackrabbit/ocm/mapper/model/ClassDescriptor.java
Date Fri, 14 Sep 2007 11:53:04 GMT
Author: fmeschbe
Date: Fri Sep 14 04:53:04 2007
New Revision: 575640

URL: http://svn.apache.org/viewvc?rev=575640&view=rev
Log:
Prevent NullPointerException in setExtend if className is null

Modified:
    jackrabbit/trunk/contrib/jackrabbit-jcr-mapping/jcr-mapping/src/main/java/org/apache/jackrabbit/ocm/mapper/model/ClassDescriptor.java

Modified: jackrabbit/trunk/contrib/jackrabbit-jcr-mapping/jcr-mapping/src/main/java/org/apache/jackrabbit/ocm/mapper/model/ClassDescriptor.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/contrib/jackrabbit-jcr-mapping/jcr-mapping/src/main/java/org/apache/jackrabbit/ocm/mapper/model/ClassDescriptor.java?rev=575640&r1=575639&r2=575640&view=diff
==============================================================================
--- jackrabbit/trunk/contrib/jackrabbit-jcr-mapping/jcr-mapping/src/main/java/org/apache/jackrabbit/ocm/mapper/model/ClassDescriptor.java
(original)
+++ jackrabbit/trunk/contrib/jackrabbit-jcr-mapping/jcr-mapping/src/main/java/org/apache/jackrabbit/ocm/mapper/model/ClassDescriptor.java
Fri Sep 14 04:53:04 2007
@@ -437,7 +437,9 @@
      * @param className
      */
     public void setExtend(String className) {
-        if (className.equals("")) className = null;
+        if (className != null && className.length() == 0) {
+            className = null;
+        }
     	this.superClassName = className;
     }
 



Mime
View raw message