[or-cvs] r11821: back out a little bit of r11817 to preserve current behavior (tor/trunk/src/or)
arma at seul.org
arma at seul.org
Tue Oct 9 21:12:48 UTC 2007
Author: arma
Date: 2007-10-09 17:12:48 -0400 (Tue, 09 Oct 2007)
New Revision: 11821
Modified:
tor/trunk/src/or/directory.c
tor/trunk/src/or/router.c
Log:
back out a little bit of r11817 to preserve current behavior.
some other behavior changes left in.
Modified: tor/trunk/src/or/directory.c
===================================================================
--- tor/trunk/src/or/directory.c 2007-10-09 21:11:16 UTC (rev 11820)
+++ tor/trunk/src/or/directory.c 2007-10-09 21:12:48 UTC (rev 11821)
@@ -272,7 +272,7 @@
{
routerstatus_t *rs = NULL;
or_options_t *options = get_options();
- int prefer_authority = dirserver_mode(options);
+ int prefer_authority = server_mode(options) && dirserver_mode(options);
int get_via_tor = purpose_needs_anonymity(dir_purpose, router_purpose);
authority_type_t type;
@@ -2753,7 +2753,8 @@
{
char digest[DIGEST_LEN];
time_t now = time(NULL);
- int server = dirserver_mode(get_options());
+ or_options_t *options = get_options();
+ int server = server_mode(options) && dirserver_mode(options);
if (!was_descriptor_digests)
return; /* FFFF should implement this someday */
SMARTLIST_FOREACH(failed, const char *, cp,
Modified: tor/trunk/src/or/router.c
===================================================================
--- tor/trunk/src/or/router.c 2007-10-09 21:11:16 UTC (rev 11820)
+++ tor/trunk/src/or/router.c 2007-10-09 21:12:48 UTC (rev 11821)
@@ -858,7 +858,7 @@
int
dirserver_mode(or_options_t *options)
{
- if (options->ClientOnly) return 0;
+// if (options->ClientOnly) return 0;
return options->DirPort != 0;
}
More information about the tor-commits
mailing list