f1ori 16 years ago
parent d69d89caed
commit 7eb3bff5b3

@ -27,6 +27,7 @@
// javac -classpath .:../Classes Status.java // javac -classpath .:../Classes Status.java
// if the shell's current path is HTROOT // if the shell's current path is HTROOT
import java.net.InetAddress;
import java.util.Date; import java.util.Date;
import de.anomic.http.httpRequestHeader; import de.anomic.http.httpRequestHeader;
@ -163,7 +164,8 @@ public class Status {
} else { } else {
prop.put("extPortFormat", "0"); prop.put("extPortFormat", "0");
} }
prop.put("host", serverDomains.myPublicLocalIP().getHostAddress()); InetAddress hostIP = serverDomains.myPublicLocalIP();
prop.put("host", hostIP!=null ? hostIP.getHostAddress() : "Unkown IP");
// ssl support // ssl support
prop.put("sslSupport",sb.getConfig("keyStore", "").length() == 0 ? "0" : "1"); prop.put("sslSupport",sb.getConfig("keyStore", "").length() == 0 ? "0" : "1");

@ -646,6 +646,7 @@ public class serverDomains {
return ia[0]; return ia[0];
} catch (final java.net.UnknownHostException e) { } catch (final java.net.UnknownHostException e) {
System.err.println("ERROR: (internal) " + e.getMessage()); System.err.println("ERROR: (internal) " + e.getMessage());
e.printStackTrace();
return null; return null;
} }
} }

Loading…
Cancel
Save