Cleanups after review and prep for release

This commit is contained in:
zzz
2009-10-11 22:51:43 +00:00
parent 92e323df51
commit 405b85c4b4
14 changed files with 49 additions and 61 deletions

View File

@ -18,9 +18,9 @@ public class RouterVersion {
/** deprecated */
public final static String ID = "Monotone";
public final static String VERSION = CoreVersion.VERSION;
public final static long BUILD = 26;
public final static long BUILD = 0;
/** for example "-test" */
public final static String EXTRA = "-rc";
public final static String EXTRA = "";
public final static String FULL_VERSION = VERSION + "-" + BUILD + EXTRA;
public static void main(String args[]) {
System.out.println("I2P Router version: " + FULL_VERSION);

View File

@ -177,7 +177,8 @@ class PeerTestManager {
testComplete(false);
} catch (UnknownHostException uhe) {
if (_log.shouldLog(Log.ERROR))
_log.error("Unable to get our IP from bob's reply: " + from + ", " + testInfo, uhe);
_log.error("Unable to get our IP (length " + ip.length +
") from bob's reply: " + from + ", " + testInfo, uhe);
}
} else {
PeerState charlieSession = _transport.getPeerState(from);

View File

@ -40,7 +40,6 @@ import net.i2p.util.SimpleTimer;
*
*/
public class UDPTransport extends TransportImpl implements TimedWeightedPriorityMessageQueue.FailedListener {
private RouterContext _rContext;
private Log _log;
private UDPEndpoint _endpoint;
/** Peer (Hash) to PeerState */

View File

@ -12,8 +12,6 @@ import net.i2p.util.Log;
*
*/
public class TunnelGatewayZeroHop extends TunnelGateway {
private RouterContext TunnelContext;
private Log TunnelLog;
private TunnelCreatorConfig _config;
private OutboundMessageDistributor _outDistributor;
private InboundMessageDistributor _inDistributor;
@ -23,11 +21,9 @@ public class TunnelGatewayZeroHop extends TunnelGateway {
*/
public TunnelGatewayZeroHop(RouterContext context, TunnelCreatorConfig config) {
super(context, null, null, null);
TunnelContext = context;
TunnelLog = context.logManager().getLog(TunnelGatewayZeroHop.class);
_config = config;
if (config.isInbound())
_inDistributor = new InboundMessageDistributor(TunnelContext, config.getDestination());
_inDistributor = new InboundMessageDistributor(context, config.getDestination());
else
_outDistributor = new OutboundMessageDistributor(context, 400);
}
@ -53,8 +49,8 @@ public class TunnelGatewayZeroHop extends TunnelGateway {
*/
@Override
public void add(I2NPMessage msg, Hash toRouter, TunnelId toTunnel) {
if (TunnelLog.shouldLog(Log.DEBUG))
TunnelLog.debug("zero hop gateway: distribute " + (_config.isInbound() ? "inbound " : " outbound ")
if (_log.shouldLog(Log.DEBUG))
_log.debug("zero hop gateway: distribute " + (_config.isInbound() ? "inbound " : " outbound ")
+ " to " + (toRouter != null ? toRouter.toBase64().substring(0,4) : "" )
+ "." + (toTunnel != null ? toTunnel.getTunnelId() + "" : "")
+ ": " + msg);