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

[or-cvs] resolve nick"s comment



Update of /home2/or/cvsroot/tor/src/or
In directory moria:/home/arma/work/onion/cvs/tor/src/or

Modified Files:
	directory.c 
Log Message:
resolve nick's comment


Index: directory.c
===================================================================
RCS file: /home2/or/cvsroot/tor/src/or/directory.c,v
retrieving revision 1.296
retrieving revision 1.297
diff -u -d -r1.296 -r1.297
--- directory.c	30 Sep 2005 01:38:09 -0000	1.296
+++ directory.c	30 Sep 2005 02:08:57 -0000	1.297
@@ -1008,20 +1008,10 @@
       tor_free(body); tor_free(headers); tor_free(reason);
       return -1;
     }
-    if (which) {
-      /* We only call these if it's a "fp/" request, since
-       * it's the only way we'll be adding new server descriptors
-       * and thus the only way we'd affect has_fetched_directory.
-       *
-       * XXXX Not so.  We will fetch "all" routers if we have zero or one
-       * networkstatus, so we can bootstrap faster.  See
-       * update_router_descriptor_downloads(). One of these behaviors is
-       * wrong.
-       **/
-
-      /* as we learn from them, we remove them from 'which' */
-      router_load_routers_from_string(body, 0, which);
-      directory_info_has_arrived(time(NULL), 0);
+    /* as we learn from them, we remove them from 'which' */
+    router_load_routers_from_string(body, 0, which);
+    directory_info_has_arrived(time(NULL), 0);
+    if (which) { /* mark remaining ones as failed */
       log_fn(LOG_NOTICE, "Received %d/%d routers.",
              n_asked_for-smartlist_len(which), n_asked_for);
       if (smartlist_len(which)) {