diff --git a/htroot/Network.java b/htroot/Network.java index 71e84719a..a3fe68768 100644 --- a/htroot/Network.java +++ b/htroot/Network.java @@ -189,9 +189,14 @@ public class Network { prop.put("table_comment_status","publish: disconnected peer '" + peer.getName() + "/" + post.get("peerHash") + "' from " + peer.getAddress()); } else { peer = yacyCore.seedDB.getConnected(peer.hash); - prop.put("table_comment",2); - prop.put("table_comment_status","publish: handshaked " + peer.get(yacySeed.PEERTYPE, yacySeed.PEERTYPE_SENIOR) + " peer '" + peer.getName() + "' at " + peer.getAddress()); - prop.put("table_comment_details",peer.toString()); + if (peer == null) { + prop.put("table_comment",1); + prop.put("table_comment_status","publish: disconnected peer '" + peer.getName() + "/" + post.get("peerHash") + "' from " + peer.getAddress()); + } else { + prop.put("table_comment",2); + prop.put("table_comment_status","publish: handshaked " + peer.get(yacySeed.PEERTYPE, yacySeed.PEERTYPE_SENIOR) + " peer '" + peer.getName() + "' at " + peer.getAddress()); + prop.put("table_comment_details",peer.toString()); + } } prop.put("table_peerHash",(String) post.get("peerHash")); diff --git a/source/de/anomic/yacy/yacyPeerActions.java b/source/de/anomic/yacy/yacyPeerActions.java index 4a2f2bab7..b9bad111e 100644 --- a/source/de/anomic/yacy/yacyPeerActions.java +++ b/source/de/anomic/yacy/yacyPeerActions.java @@ -282,7 +282,7 @@ public class yacyPeerActions { if (Math.abs(nowUTC0Time - ctimeUTC0) > 3600000) { // the new connection is out-of-age, we reject the connection yacyCore.log.logFine("connect: rejecting out-dated peer '" + seed.getName() + "' from " + seed.getAddress() + - "; nowUTC0=" + nowUTC0Time + ", seedUTC0=" + ctimeUTC0); + "; nowUTC0=" + nowUTC0Time + ", seedUTC0=" + ctimeUTC0 + ", TimeDiff=" + serverDate.intervalToString(Math.abs(nowUTC0Time - ctimeUTC0))); return false; }