aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2006-06-18 08:16:05 +0000
committerNick Mathewson <nickm@torproject.org>2006-06-18 08:16:05 +0000
commitb9013cbe98e96cb857337c6481ecf192cd51c9fc (patch)
treefe70ab6298e3f1c87904484bab64d236dc33af50 /src
parentc374340c7020d7c399754e3e3ffa190d3840c941 (diff)
downloadtor-b9013cbe98e96cb857337c6481ecf192cd51c9fc.tar
tor-b9013cbe98e96cb857337c6481ecf192cd51c9fc.tar.gz
And actually check the url when it exists. that might work better.
svn:r6646
Diffstat (limited to 'src')
-rw-r--r--src/or/directory.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/or/directory.c b/src/or/directory.c
index 951b9e3ae..2aaa9f2c4 100644
--- a/src/or/directory.c
+++ b/src/or/directory.c
@@ -1522,6 +1522,10 @@ directory_handle_command_get(connection_t *conn, char *headers,
request_type = deflated?"/tor/server/d.z":"/tor/server/d";
else
request_type = "/tor/server/?";
+ 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;
tor_free(url);
if (res < 0)
write_http_status_line(conn, 404, msg);
@@ -1545,10 +1549,6 @@ 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;