summaryrefslogtreecommitdiff
path: root/src/or
diff options
context:
space:
mode:
authorRoger Dingledine <arma@torproject.org>2008-12-07 01:34:45 +0000
committerRoger Dingledine <arma@torproject.org>2008-12-07 01:34:45 +0000
commit21892d8a9c29ad8e1ec09738adefe7aeb40dfa79 (patch)
tree69120916ed78cdacbd73be780366cc4fe833548b /src/or
parent6b178b46ef52fc146fee566e9bdd12929d3ad0a3 (diff)
downloadtor-21892d8a9c29ad8e1ec09738adefe7aeb40dfa79.tar.gz
tor-21892d8a9c29ad8e1ec09738adefe7aeb40dfa79.zip
cleanups on r17500
svn:r17501
Diffstat (limited to 'src/or')
-rw-r--r--src/or/config.c2
-rw-r--r--src/or/directory.c4
2 files changed, 4 insertions, 2 deletions
diff --git a/src/or/config.c b/src/or/config.c
index f08a55dd46..3deebf89bb 100644
--- a/src/or/config.c
+++ b/src/or/config.c
@@ -756,7 +756,7 @@ static char *torrc_fname = NULL;
static or_state_t *global_state = NULL;
/** Configuration Options set by command line. */
static config_line_t *global_cmdline_options = NULL;
-/** Contents of most recently read DirPortFrontPage option file. */
+/** Contents of most recently read DirPortFrontPage file. */
static char *global_dirfrontpagecontents = NULL;
/** Return the contents of our frontpage string, or NULL if not configured. */
diff --git a/src/or/directory.c b/src/or/directory.c
index 14470060a0..3cf6e366cd 100644
--- a/src/or/directory.c
+++ b/src/or/directory.c
@@ -2479,7 +2479,8 @@ directory_handle_command_get(dir_connection_t *conn, const char *headers,
if (frontpage) {
dlen = strlen(frontpage);
- /* Lets return a disclaimer, users shouldn't use V1 anymore */
+ /* Let's return a disclaimer page (users shouldn't use V1 anymore,
+ and caches don't fetch '/', so this is safe). */
if (global_write_bucket_low(TO_CONN(conn), dlen, 1)) {
log_info(LD_DIRSERV,
"Client asked for DirPortFrontPage content, but we've been "
@@ -2493,6 +2494,7 @@ directory_handle_command_get(dir_connection_t *conn, const char *headers,
connection_write_to_buf(frontpage, dlen, TO_CONN(conn));
goto done;
}
+ /* if no disclaimer file, fall through and continue */
}
if (!strcmp(url,"/tor/") || !strcmp(url,"/tor/dir")) { /* v1 dir fetch */