[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[or-cvs] don"t whine about reachability if the guy is hibernating now.
Update of /home2/or/cvsroot/tor/src/or
In directory moria:/home/arma/work/onion/cvs/tor/src/or
Modified Files:
dirserv.c or.h
Log Message:
don't whine about reachability if the guy is hibernating now.
speaking of which, we don't actually parse is_hibernating out
of the router descriptor right now. nick, can you fix this?
Index: dirserv.c
===================================================================
RCS file: /home2/or/cvsroot/tor/src/or/dirserv.c,v
retrieving revision 1.200
retrieving revision 1.201
diff -u -d -r1.200 -r1.201
--- dirserv.c 30 Aug 2005 06:43:07 -0000 1.200
+++ dirserv.c 30 Aug 2005 06:48:24 -0000 1.201
@@ -508,6 +508,8 @@
dirserv_thinks_router_is_blatantly_unreachable(routerinfo_t *router, time_t now)
{
connection_t *conn;
+ if (router->is_hibernating)
+ return 0;
conn = connection_get_by_identity_digest(router->identity_digest,
CONN_TYPE_OR);
if (conn && conn->state == OR_CONN_STATE_OPEN &&
Index: or.h
===================================================================
RCS file: /home2/or/cvsroot/tor/src/or/or.h,v
retrieving revision 1.660
retrieving revision 1.661
diff -u -d -r1.660 -r1.661
--- or.h 30 Aug 2005 06:43:07 -0000 1.660
+++ or.h 30 Aug 2005 06:48:24 -0000 1.661
@@ -736,6 +736,7 @@
addr_policy_t *exit_policy; /**< What streams will this OR permit
* to exit? */
long uptime; /**< How many seconds the router claims to have been up */
+ uint8_t is_hibernating; /**< Whether the router claims to be hibernating */
smartlist_t *declared_family; /**< Nicknames of router which this router
* claims are its family. */
char *contact_info; /**< Declared contact info for this router. */
@@ -747,7 +748,7 @@
* (For Authdir: Have we validated this OR?)
*/
- /* The below items are used only by authdirservers right now for
+ /* The below items are used only by authdirservers for
* reachability testing. */
time_t last_reachable; /**< When was the last time we could reach this OR? */
time_t testing_since; /**< When did we start testing reachability for this OR? */