You are viewing a plain text version of this content. The canonical link for it is here.
Posted to server-dev@james.apache.org by no...@apache.org on 2006/12/14 18:58:15 UTC

svn commit: r487280 - /james/server/trunk/src/java/org/apache/james/James.java

Author: norman
Date: Thu Dec 14 09:58:14 2006
New Revision: 487280

URL: http://svn.apache.org/viewvc?view=rev&rev=487280
Log:
Get sure a exception is thrown if virtualhosting is enabled and no defaultdomain is used

Modified:
    james/server/trunk/src/java/org/apache/james/James.java

Modified: james/server/trunk/src/java/org/apache/james/James.java
URL: http://svn.apache.org/viewvc/james/server/trunk/src/java/org/apache/james/James.java?view=diff&rev=487280&r1=487279&r2=487280
==============================================================================
--- james/server/trunk/src/java/org/apache/james/James.java (original)
+++ james/server/trunk/src/java/org/apache/james/James.java Thu Dec 14 09:58:14 2006
@@ -268,6 +268,8 @@
         Configuration defaultDomainConfig = conf.getChild("defaultDomain");
         if (defaultDomainConfig != null ) {
             defaultDomain = defaultDomainConfig.getValue(null);
+        } else if (virtualHosting) {
+            throw new ConfigurationException("Please configure a defaultDomain if using VirtualHosting");
         }
         
         getLogger().info("Defaultdomain: " + defaultDomain);
@@ -282,7 +284,7 @@
                     helloName = "localhost";
                 }
             } else {
-             // Should we use the defaultdomain here ?
+                // Should we use the defaultdomain here ?
                 helloName = helloNameConfig.getValue(defaultDomain);
             }
             attributes.put(Constants.HELLO_NAME, helloName);



---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org