Skip to content

Distributed Peer-to-Peer Web Search Engine and Intranet Search Appliance

fix for npe

orbiterd260b25457c7
diff --git a/htroot/ConfigPortal.java b/htroot/ConfigPortal.java
index ee91eca04..58688b35e 100644
--- a/htroot/ConfigPortal.java
+++ b/htroot/ConfigPortal.java
@@ -161,7 +161,7 @@ public class ConfigPortal {
prop.put("selected_top", "_top".equals(target) ? 1 : 0);
prop.put("selected_searchresult", "searchresult".equals(target) ? 1 : 0);
- String myaddress = sb.peers.mySeed().getPublicAddress();
+ String myaddress = (sb.peers == null) ? null : sb.peers.mySeed() == null ? null : sb.peers.mySeed().getPublicAddress();
if (myaddress == null) {
myaddress = "localhost:" + sb.getConfig("port", "8090");
}