tuscany-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From antel...@apache.org
Subject svn commit: r945640 - /tuscany/sca-java-2.x/trunk/modules/node-api/src/main/java/org/apache/tuscany/sca/node/NodeFactory.java
Date Tue, 18 May 2010 13:10:12 GMT
Author: antelder
Date: Tue May 18 13:10:12 2010
New Revision: 945640

URL: http://svn.apache.org/viewvc?rev=945640&view=rev
Log:
Avoid NPE by not setting null in domain name

Modified:
    tuscany/sca-java-2.x/trunk/modules/node-api/src/main/java/org/apache/tuscany/sca/node/NodeFactory.java

Modified: tuscany/sca-java-2.x/trunk/modules/node-api/src/main/java/org/apache/tuscany/sca/node/NodeFactory.java
URL: http://svn.apache.org/viewvc/tuscany/sca-java-2.x/trunk/modules/node-api/src/main/java/org/apache/tuscany/sca/node/NodeFactory.java?rev=945640&r1=945639&r2=945640&view=diff
==============================================================================
--- tuscany/sca-java-2.x/trunk/modules/node-api/src/main/java/org/apache/tuscany/sca/node/NodeFactory.java
(original)
+++ tuscany/sca-java-2.x/trunk/modules/node-api/src/main/java/org/apache/tuscany/sca/node/NodeFactory.java
Tue May 18 13:10:12 2010
@@ -554,7 +554,9 @@ public abstract class NodeFactory extend
     private NodeConfiguration createConfiguration(Contribution... contributions) {
         NodeConfigurationFactory factory = this;
         NodeConfiguration configuration = factory.createNodeConfiguration();
-        configuration.setDomainURI(properties.getProperty("defaultDomainName"));
+        if (properties.getProperty("defaultDomainName") != null) {
+            configuration.setDomainURI(properties.getProperty("defaultDomainName"));
+        }
         // Make sure a unique node URI is created for the same node factory
         configuration.setURI(generateNodeURI());
         if (contributions != null) {



Mime
View raw message