]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
checking "same addr/port but with nonmatching keys" is obsolete
authorRoger Dingledine <arma@torproject.org>
Thu, 29 Mar 2012 20:45:25 +0000 (16:45 -0400)
committerRoger Dingledine <arma@torproject.org>
Thu, 29 Mar 2012 20:45:25 +0000 (16:45 -0400)
Specifically, I believe it dates back to when extend cells had address:port
but no digest in them. The special edge case is certainly not worth the
complexity these days.

src/or/dirserv.c

index 467129c7286a526bc1e8157652412d40ac18a4b2..dfecbc8a098d9dc5c38b76f59d73c4948ddd514b 100644 (file)
@@ -3271,16 +3271,11 @@ dirserv_orconn_tls_done(const char *address,
                         uint16_t or_port,
                         const char *digest_rcvd)
 {
-  routerinfo_t *ri = NULL;
+  routerinfo_t *ri = router_get_mutable_by_digest(digest_rcvd);
   time_t now = time(NULL);
   tor_assert(address);
   tor_assert(digest_rcvd);
 
-  /* FFFF Maybe we should reinstate the code that dumps routers with the same
-   * addr/port but with nonmatching keys, but instead of dumping, we should
-   * skip testing. */
-
-  ri = router_get_mutable_by_digest(digest_rcvd);
   if (ri == NULL)
     return;