merge of '7e9ec9156e65514e00e0d9f82be002cf9aadac5f'

and '9df57c2abc8e859828f9edf80e9d104fd6bf6729'
This commit is contained in:
dev
2010-03-15 19:01:28 +00:00
16 changed files with 54 additions and 35 deletions

View File

@ -19,7 +19,7 @@ public class TunnelBuildMessage extends I2NPMessageImpl {
this(context, MAX_RECORD_COUNT);
}
/** @since 0.7.10 */
/** @since 0.7.12 */
protected TunnelBuildMessage(I2PAppContext context, int records) {
super(context);
if (records > 0) {
@ -31,7 +31,7 @@ public class TunnelBuildMessage extends I2NPMessageImpl {
public void setRecord(int index, ByteArray record) { _records[index] = record; }
public ByteArray getRecord(int index) { return _records[index]; }
/** @since 0.7.10 */
/** @since 0.7.12 */
public int getRecordCount() { return RECORD_COUNT; }
public static final int RECORD_SIZE = 512+16;

View File

@ -20,7 +20,7 @@ public class TunnelBuildReplyMessage extends I2NPMessageImpl {
this(context, MAX_RECORD_COUNT);
}
/** @since 0.7.10 */
/** @since 0.7.12 */
protected TunnelBuildReplyMessage(I2PAppContext context, int records) {
super(context);
if (records > 0) {
@ -32,7 +32,7 @@ public class TunnelBuildReplyMessage extends I2NPMessageImpl {
public void setRecord(int index, ByteArray record) { _records[index] = record; }
public ByteArray getRecord(int index) { return _records[index]; }
/** @since 0.7.10 */
/** @since 0.7.12 */
public int getRecordCount() { return RECORD_COUNT; }
public static final int RECORD_SIZE = TunnelBuildMessage.RECORD_SIZE;

View File

@ -18,10 +18,10 @@ public class RouterVersion {
/** deprecated */
public final static String ID = "Monotone";
public final static String VERSION = CoreVersion.VERSION;
public final static long BUILD = 11;
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

@ -93,6 +93,8 @@ public class ClientAppConfig {
/*
* Go through the properties, and return a List of ClientAppConfig structures
*
* @since 0.7.12
*/
public static List<ClientAppConfig> getClientApps(File cfgFile) {
Properties clientApps = new Properties();
@ -106,6 +108,8 @@ public class ClientAppConfig {
/*
* Go through the properties, and return a List of ClientAppConfig structures
*
* @since 0.7.12
*/
private static List<ClientAppConfig> getClientApps(Properties clientApps) {
List<ClientAppConfig> rv = new ArrayList(8);

View File

@ -506,6 +506,7 @@ class BuildExecutor implements Runnable {
/**
* Only do this for non-fallback tunnels.
* @return true if refused because of a duplicate key
* @since 0.7.12
*/
private boolean addToBuilding(PooledTunnelCreatorConfig cfg) {
//_log.error("Adding ID: " + cfg.getReplyMessageId() + "; size was: " + _currentlyBuildingMap.size());
@ -521,6 +522,7 @@ class BuildExecutor implements Runnable {
* But that's ok. A peer that rejects slowly gets penalized twice, for example.
*
* @return ptcc or null
* @since 0.7.12
*/
PooledTunnelCreatorConfig removeFromBuilding(long id) {
//_log.error("Removing ID: " + id + "; size was: " + _currentlyBuildingMap.size());

View File

@ -187,6 +187,7 @@ class BuildRequestor {
SHORT_ORDER.add(Integer.valueOf(i));
}
/** @since 0.7.12 */
private static boolean supportsVariable(RouterContext ctx, Hash h) {
RouterInfo ri = ctx.netDb().lookupRouterInfoLocally(h);
if (ri == null)