Distributed Peer-to-Peer Web Search Engine and Intranet Search Appliance
Java decentralizedintranet-searchintranet-search-enginep2pp2p-networkprivacyprivacy-protectionsearch-enginesearchenginewebweb-search-enginewebsearchwebseearch-engine
NPE fix
Michael Peter Christenbef689d0a2e0
diff --git a/htroot/ConfigPortal.java b/htroot/ConfigPortal.javaindex cedcdbf9b..58eb3d633 100644--- a/htroot/ConfigPortal.java+++ b/htroot/ConfigPortal.java@@ -219,7 +219,7 @@ public class ConfigPortal {prop.put("target_selected_special_searchresult", "searchresult".equals(target_special) ? 1 : 0);prop.put("target_special_pattern", sb.getConfig(SwitchboardConstants.SEARCH_TARGET_SPECIAL_PATTERN, ""));- String myaddress = (sb.peers == null) ? null : sb.peers.mySeed() == null ? null : sb.peers.mySeed().getPublicAddress(sb.peers.mySeed().getIP());+ String myaddress = (sb.peers == null) || sb.peers.mySeed() == null || sb.peers.mySeed().getIP() == null ? null : sb.peers.mySeed().getPublicAddress(sb.peers.mySeed().getIP());if (myaddress == null) {myaddress = "localhost:" + sb.getLocalPort("port", 8090);}diff --git a/htroot/ViewLog_p.java b/htroot/ViewLog_p.javaindex 6e3ef1bea..a5783226e 100644--- a/htroot/ViewLog_p.java+++ b/htroot/ViewLog_p.java@@ -102,6 +102,7 @@ public class ViewLog_p {int level = 0;int lc = 0;for (final String logLine : log) {+ if (logLine == null) break;final String nextLogLine = logLine.trim();if (filterMatcher != null) {