tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From fha...@apache.org
Subject svn commit: r393653 - /tomcat/container/tc5.5.x/webapps/admin/WEB-INF/classes/org/apache/webapp/admin/connector/EditConnectorAction.java
Date Wed, 12 Apr 2006 23:16:58 GMT
Author: fhanik
Date: Wed Apr 12 16:16:56 2006
New Revision: 393653

URL: http://svn.apache.org/viewcvs?rev=393653&view=rev
Log:
Fix for http://issues.apache.org/bugzilla/show_bug.cgi?id=35064
Fix submitted by amilaSuriarachchi@gmail.com

Modified:
    tomcat/container/tc5.5.x/webapps/admin/WEB-INF/classes/org/apache/webapp/admin/connector/EditConnectorAction.java

Modified: tomcat/container/tc5.5.x/webapps/admin/WEB-INF/classes/org/apache/webapp/admin/connector/EditConnectorAction.java
URL: http://svn.apache.org/viewcvs/tomcat/container/tc5.5.x/webapps/admin/WEB-INF/classes/org/apache/webapp/admin/connector/EditConnectorAction.java?rev=393653&r1=393652&r2=393653&view=diff
==============================================================================
--- tomcat/container/tc5.5.x/webapps/admin/WEB-INF/classes/org/apache/webapp/admin/connector/EditConnectorAction.java
(original)
+++ tomcat/container/tc5.5.x/webapps/admin/WEB-INF/classes/org/apache/webapp/admin/connector/EditConnectorAction.java
Wed Apr 12 16:16:56 2006
@@ -41,7 +41,7 @@
 import org.apache.webapp.admin.LabelValueBean;
 import org.apache.webapp.admin.Lists;
 import org.apache.webapp.admin.TomcatTreeBuilder;
-
+import java.net.InetAddress;
 /**
  * The <code>Action</code> that sets up <em>Edit Connector</em> transactions.
  *
@@ -170,9 +170,15 @@
             connectorFm.setEnableLookups
                 (String.valueOf(mBServer.getAttribute(cname, attribute)));            
             attribute = "address";
-            connectorFm.setAddress
-                ((String) mBServer.getAttribute(cname, attribute));          
-            attribute = "maxKeepAliveRequests";
+            Object addressObject = mBServer.getAttribute(cname, attribute);
+	    String addressStr = "";
+	    if (addressObject instanceof InetAddress){
+	        addressStr = ((InetAddress)addressObject).getHostAddress();
+	    } else if (addressObject instanceof String) {
+	        addressStr = (String) addressObject;
+	    }
+	    connectorFm.setAddress(addressStr);
+	    attribute = "maxKeepAliveRequests";
             connectorFm.setMaxKeepAliveText
                 (String.valueOf(mBServer.getAttribute(cname, attribute)));       
             attribute = "maxSpareThreads";



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


Mime
View raw message