]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
That dir_refresh_src fix will only work if I enable it.
authorNick Mathewson <nickm@torproject.org>
Sun, 18 Jun 2006 08:13:45 +0000 (08:13 +0000)
committerNick Mathewson <nickm@torproject.org>
Sun, 18 Jun 2006 08:13:45 +0000 (08:13 +0000)
svn:r6645

src/or/directory.c

index 7da5aa4312c6f552300937a4452e936f3bc129d6..951b9e3ae2bc534cd0d509dbc84743529708b3ef 100644 (file)
@@ -1418,6 +1418,7 @@ directory_handle_command_get(connection_t *conn, char *headers,
     ++d->refcnt;
 
     /* Prime the connection with some data. */
+    conn->dir_refresh_src = DIR_REFRESH_CACHED_DIR;
     connection_dirserv_flushed_some(conn);
     return 0;
   }
@@ -1544,6 +1545,10 @@ directory_handle_command_get(connection_t *conn, char *headers,
         connection_write_to_buf(tmp, strlen(tmp), conn);
       }
       /* Prime the connection with some data. */
+      if (!strcmpstart(url, "/tor/server/d/"))
+        conn->dir_refresh_src = DIR_REFRESH_SERVER_BY_DIGEST;
+      else
+        conn->dir_refresh_src = DIR_REFRESH_SERVER_BY_FP;
       connection_dirserv_flushed_some(conn);
     }
     return 0;