Is the peers list always written on shutdown?

On Tuesday 14 April 2009 18:59:49 dconr...@freenetproject.org wrote:
> Author: dconrado
> Date: 2009-04-14 17:59:48 +0000 (Tue, 14 Apr 2009)
> New Revision: 26786
> 
> Modified:
>    trunk/freenet/src/freenet/node/PeerNode.java
> Log:
> Added red color into infobox Confirm external link.
> 
> 
> Modified: trunk/freenet/src/freenet/node/PeerNode.java
> ===================================================================
> --- trunk/freenet/src/freenet/node/PeerNode.java      2009-04-14 17:43:13 UTC 
(rev 26785)
> +++ trunk/freenet/src/freenet/node/PeerNode.java      2009-04-14 17:59:48 UTC 
(rev 26786)
> @@ -235,6 +235,10 @@
>       private int messageRequeueLogRateLimitThreshold = 15;
>       /** Version of the node */
>       private String version;
> +     /** Total input */
> +     private long totalInput;
> +     /** Total output */
> +     private long totalOutput;
>       /** Peer node crypto group; changing this means new noderef */
>       final DSAGroup peerCryptoGroup;
>  
> @@ -707,6 +711,9 @@
>               else
>                       sendHandshakeTime = now;  // Be sure we're ready to 
> handshake right away
>  
> +             totalInput = Long.parseLong(fs.get("totalinput"));
> +             totalOutput = Long.parseLong(fs.get("totaloutput"));
> +
>       // status may have changed from PEER_NODE_STATUS_DISCONNECTED to 
PEER_NODE_STATUS_NEVER_CONNECTED
>       }
>  
> @@ -2701,6 +2708,8 @@
>               }
>               fs.put("opennet", isOpennet());
>               fs.put("seed", isSeed());
> +             fs.put("totalinput", getTotalInputBytes());
> +             fs.put("totaloutput", getTotalOutputBytes());   
>               return fs;
>       }

Attachment: signature.asc
Description: This is a digitally signed message part.

_______________________________________________
Devl mailing list
Devl@freenetproject.org
http://emu.freenetproject.org/cgi-bin/mailman/listinfo/devl

Reply via email to