geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d...@apache.org
Subject svn commit: r519061 - /geronimo/server/trunk/modules/geronimo-openejb-builder/src/main/java/org/apache/geronimo/openejb/deployment/EjbModuleBuilder.java
Date Fri, 16 Mar 2007 17:03:19 GMT
Author: dain
Date: Fri Mar 16 10:03:18 2007
New Revision: 519061

URL: http://svn.apache.org/viewvc?view=rev&rev=519061
Log:
Fixed null pointer exception

Modified:
    geronimo/server/trunk/modules/geronimo-openejb-builder/src/main/java/org/apache/geronimo/openejb/deployment/EjbModuleBuilder.java

Modified: geronimo/server/trunk/modules/geronimo-openejb-builder/src/main/java/org/apache/geronimo/openejb/deployment/EjbModuleBuilder.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-openejb-builder/src/main/java/org/apache/geronimo/openejb/deployment/EjbModuleBuilder.java?view=diff&rev=519061&r1=519060&r2=519061
==============================================================================
--- geronimo/server/trunk/modules/geronimo-openejb-builder/src/main/java/org/apache/geronimo/openejb/deployment/EjbModuleBuilder.java
(original)
+++ geronimo/server/trunk/modules/geronimo-openejb-builder/src/main/java/org/apache/geronimo/openejb/deployment/EjbModuleBuilder.java
Fri Mar 16 10:03:18 2007
@@ -506,9 +506,12 @@
             // todo Persistence Unit Data Sources need to be global JNDI names
             Object altDD = ejbModule.getEjbModule().getAltDDs().get("openejb-jar.xml");
             if (altDD instanceof OpenejbJarType) {
-                String datasourceName = ((OpenejbJarType) altDD).getCmpConnectionFactory().getResourceLink();
-                if (datasourceName != null) {
-                    jtaDataSource = "?name=" + datasourceName;
+                ResourceLocatorType cmpConnectionFactory = ((OpenejbJarType) altDD).getCmpConnectionFactory();
+                if (cmpConnectionFactory != null) {
+                    String datasourceName = cmpConnectionFactory.getResourceLink();
+                    if (datasourceName != null) {
+                        jtaDataSource = "?name=" + datasourceName;
+                    }
                 }
             }
 



Mime
View raw message