[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[or-cvs] r12960: The bridge GeoIP stats were counting other relays, for examp (in tor/trunk: . doc src/or)



Author: arma
Date: 2007-12-24 19:07:13 -0500 (Mon, 24 Dec 2007)
New Revision: 12960

Modified:
   tor/trunk/ChangeLog
   tor/trunk/doc/TODO
   tor/trunk/src/or/connection_or.c
Log:
The bridge GeoIP stats were counting other relays, for example
self-reachability and authority-reachability tests.


Modified: tor/trunk/ChangeLog
===================================================================
--- tor/trunk/ChangeLog	2007-12-24 23:51:22 UTC (rev 12959)
+++ tor/trunk/ChangeLog	2007-12-25 00:07:13 UTC (rev 12960)
@@ -15,6 +15,8 @@
       previously unreachable, mark it as retriable so we won't just
       ignore it. Also, try fetching a new copy immediately. Bugfixes
       on 0.2.0.13-alpha.
+    - The bridge GeoIP stats were counting other relays, for example
+      self-reachability and authority-reachability tests.
 
   o Minor features:
     - Support compilation to target iPhone; patch from cjacker huang.

Modified: tor/trunk/doc/TODO
===================================================================
--- tor/trunk/doc/TODO	2007-12-24 23:51:22 UTC (rev 12959)
+++ tor/trunk/doc/TODO	2007-12-25 00:07:13 UTC (rev 12960)
@@ -48,7 +48,7 @@
       - Write some basic unit tests.
     - Mention in dir-spec.txt
     - Mention in control-spec.txt
-    - we count hits from our reachability tests too. stop that somehow.
+    o we count hits from our reachability tests too. stop that somehow.
     - have normal relays report geoip stats too.
     - different thresholds for bridges than for normal relays.
     d let Vidalia use the geoip data too rather than doing its own

Modified: tor/trunk/src/or/connection_or.c
===================================================================
--- tor/trunk/src/or/connection_or.c	2007-12-24 23:51:22 UTC (rev 12959)
+++ tor/trunk/src/or/connection_or.c	2007-12-25 00:07:13 UTC (rev 12960)
@@ -906,7 +906,9 @@
     }
     router_set_status(conn->identity_digest, 1);
   } else {
-    geoip_note_client_seen(TO_CONN(conn)->addr, now);
+    /* only report it to the geoip module if it's not a known router */
+    if (!router_get_by_digest(conn->identity_digest))
+      geoip_note_client_seen(TO_CONN(conn)->addr, now);
   }
   if (conn->handshake_state) {
     or_handshake_state_free(conn->handshake_state);