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

[or-cvs] r13392: Remove a few #if-0d items. (in tor/trunk: . src/common src/or)



Author: nickm
Date: 2008-02-05 16:39:56 -0500 (Tue, 05 Feb 2008)
New Revision: 13392

Modified:
   tor/trunk/
   tor/trunk/src/common/tortls.h
   tor/trunk/src/or/command.c
   tor/trunk/src/or/connection.c
   tor/trunk/src/or/or.h
   tor/trunk/src/or/routerlist.c
Log:
 r17918@catbus:  nickm | 2008-02-05 16:39:17 -0500
 Remove a few #if-0d items.



Property changes on: tor/trunk
___________________________________________________________________
 svk:merge ticket from /tor/trunk [r17918] on 8246c3cf-6607-4228-993b-4d95d33730f1

Modified: tor/trunk/src/common/tortls.h
===================================================================
--- tor/trunk/src/common/tortls.h	2008-02-05 21:39:51 UTC (rev 13391)
+++ tor/trunk/src/common/tortls.h	2008-02-05 21:39:56 UTC (rev 13392)
@@ -66,15 +66,6 @@
 crypto_pk_env_t *tor_tls_dup_private_key(tor_tls_t *tls);
 int tor_tls_verify_v1(int severity, tor_tls_t *tls,
                       crypto_pk_env_t **identity);
-#if 0
-int tor_tls_verify_certs_v2(int severity, tor_tls_t *tls,
-                            const char *cert_str, size_t cert_len,
-                            const char *id_cert_str, size_t id_cert_len,
-                            crypto_pk_env_t **cert_key_out,
-                            char *conn_cert_digest_out,
-                            crypto_pk_env_t **id_key_out,
-                            char *id_digest_out);
-#endif
 int tor_tls_check_lifetime(tor_tls_t *tls, int tolerance);
 int tor_tls_read(tor_tls_t *tls, char *cp, size_t len);
 int tor_tls_write(tor_tls_t *tls, const char *cp, size_t n);

Modified: tor/trunk/src/or/command.c
===================================================================
--- tor/trunk/src/or/command.c	2008-02-05 21:39:51 UTC (rev 13391)
+++ tor/trunk/src/or/command.c	2008-02-05 21:39:56 UTC (rev 13392)
@@ -39,10 +39,6 @@
 static void command_process_versions_cell(var_cell_t *cell,
                                           or_connection_t *conn);
 static void command_process_netinfo_cell(cell_t *cell, or_connection_t *conn);
-#if 0
-static void command_process_cert_cell(var_cell_t *cell, or_connection_t *conn);
-static void command_process_link_auth_cell(cell_t *cell,or_connection_t *conn);
-#endif
 
 #ifdef KEEP_TIMING_STATS
 /** This is a wrapper function around the actual function that processes the

Modified: tor/trunk/src/or/connection.c
===================================================================
--- tor/trunk/src/or/connection.c	2008-02-05 21:39:51 UTC (rev 13391)
+++ tor/trunk/src/or/connection.c	2008-02-05 21:39:56 UTC (rev 13392)
@@ -2418,26 +2418,6 @@
   return NULL;
 }
 
-#if 0
-/** Return the connection of type <b>type</b> that is in state
- * <b>state</b>, that was written to least recently, and that is not
- * marked for close.
- */
-connection_t *
-connection_get_by_type_state_lastwritten(int type, int state)
-{
-  connection_t *best = NULL;
-  smartlist_t *conns = get_connection_array();
-  SMARTLIST_FOREACH(conns, connection_t *, conn,
-  {
-    if (conn->type == type && conn->state == state && !conn->marked_for_close)
-      if (!best || conn->timestamp_lastwritten < best->timestamp_lastwritten)
-        best = conn;
-  });
-  return best;
-}
-#endif
-
 /** Return a connection of type <b>type</b> that has rendquery equal
  * to <b>rendquery</b>, and that is not marked for close. If state
  * is non-zero, conn must be of that state too.

Modified: tor/trunk/src/or/or.h
===================================================================
--- tor/trunk/src/or/or.h	2008-02-05 21:39:51 UTC (rev 13391)
+++ tor/trunk/src/or/or.h	2008-02-05 21:39:56 UTC (rev 13392)
@@ -3814,11 +3814,6 @@
   /** What kind of authority is this? (Bitfield.) */
   authority_type_t type;
 
-#if 0
-  smartlist_t *v3_certs; /**< V3 key certificates for this authority */
-  download_status_t cert_dl_status; /**< Status of downloading this server's
-                               * latest certificate. */
-#endif
   download_status_t v2_ns_dl_status; /**< Status of downloading this server's
                                * v2 network status. */
   time_t addr_current_at; /**< When was the document that we derived the

Modified: tor/trunk/src/or/routerlist.c
===================================================================
--- tor/trunk/src/or/routerlist.c	2008-02-05 21:39:51 UTC (rev 13391)
+++ tor/trunk/src/or/routerlist.c	2008-02-05 21:39:56 UTC (rev 13392)
@@ -143,16 +143,6 @@
     ds = trusteddirserver_get_by_v3_auth_digest(
                                        cert->cache_info.identity_digest);
 
-#if 0
-    if (drop_unknown && !ds) {
-        log_info(LD_DIR, "Found %s certificate whose key didn't match "
-                 "any v3 authority we recognized; skipping.",
-                 from_store ? "cached" : "downloaded");
-        authority_cert_free(cert);
-        continue;
-      }
-    }
-#endif
     cl = get_cert_list(cert->cache_info.identity_digest);
 
     SMARTLIST_FOREACH(cl->certs, authority_cert_t *, c,
@@ -2717,11 +2707,6 @@
     return -1;
   }
 
-#if 0
-  if (routerlist_is_overfull(routerlist))
-    routerlist_remove_old_routers();
-#endif
-
   if (authdir) {
     if (authdir_wants_to_reject_router(router, msg,
                                        !from_cache && !from_fetch)) {