Changeset c46b06f


Ignore:
Timestamp:
Mar 1, 2008 4:13:41 PM (13 years ago)
Author:
zzz <zzz@…>
Branches:
master
Children:
1ecb84f, cffcbe5
Parents:
a739787
Message:

Fix netdb.knownLeaseSets count reported by floodfill routers

Files:
4 edited

Legend:

Unmodified
Added
Removed
  • history.txt

    ra739787 rc46b06f  
     12008-03-01 zzz
     2    * Fix netdb.knownLeaseSets count reported by floodfill routers
     3      (was broken by -3)
     4
    152008-02-27 zzz
    26    * i2ptunnel: Add 3-hop option to edit.jsp to match configtunnels.jsp
  • router/java/src/net/i2p/router/RouterVersion.java

    ra739787 rc46b06f  
    1818    public final static String ID = "$Revision: 1.548 $ $Date: 2008-02-10 15:00:00 $";
    1919    public final static String VERSION = "0.6.1.31";
    20     public final static long BUILD = 8;
     20    public final static long BUILD = 9;
    2121    public static void main(String args[]) {
    2222        System.out.println("I2P Router version: " + VERSION + "-" + BUILD);
  • router/java/src/net/i2p/router/networkdb/kademlia/PersistentDataStore.java

    ra739787 rc46b06f  
    7272    }
    7373   
     74/*
     75 *  We don't store leasesets here anymore, use the TransientDataStore count
     76 *
    7477    public int countLeaseSets() {
    7578        File dbDir = null;
     
    8790            return leaseSetFiles.length;
    8891    }
     92*/
    8993   
    9094    private void accept(LeaseSet ls) {
  • router/java/src/net/i2p/router/networkdb/kademlia/TransientDataStore.java

    ra739787 rc46b06f  
    6161    }
    6262
    63     public int countLeaseSets() { return 0; }
    64 
     63    public int countLeaseSets() {
     64        int count = 0;
     65        synchronized (_data) {
     66            for (Iterator iter = _data.values().iterator(); iter.hasNext();) {
     67                DataStructure data = (DataStructure)iter.next();
     68                if (data instanceof LeaseSet)
     69                    count++;
     70            }
     71        }
     72        return count;
     73    }
    6574   
    6675    /** nothing published more than 5 minutes in the future */
Note: See TracChangeset for help on using the changeset viewer.