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

[or-cvs] r12730: only clear the bridge list if options->Bridges is set. this (tor/trunk/src/or)



Author: arma
Date: 2007-12-08 22:38:57 -0500 (Sat, 08 Dec 2007)
New Revision: 12730

Modified:
   tor/trunk/src/or/config.c
Log:
only clear the bridge list if options->Bridges is set.
this doesn't matter yet so we aren't adding them in other
ways yet.


Modified: tor/trunk/src/or/config.c
===================================================================
--- tor/trunk/src/or/config.c	2007-12-09 03:23:16 UTC (rev 12729)
+++ tor/trunk/src/or/config.c	2007-12-09 03:38:57 UTC (rev 12730)
@@ -986,8 +986,8 @@
       add_default_trusted_dirservers();
   }
 
-  clear_bridge_list();
   if (options->Bridges) {
+    clear_bridge_list();
     for (cl = options->Bridges; cl; cl = cl->next) {
       if (parse_bridge_line(cl->value, 0)<0) {
         log_warn(LD_BUG,
@@ -1026,7 +1026,7 @@
 
   /* Bail out at this point if we're not going to be a client or server:
    * we want to not fork, and to log stuff to stderr. */
-  if (options->command != CMD_RUN_TOR)
+  if (!running_tor)
     return 0;
 
   {
@@ -1079,9 +1079,6 @@
   if (accounting_is_enabled(options))
     configure_accounting(time(NULL));
 
-  if (!running_tor)
-    return 0;
-
   /* Check for transitions that need action. */
   if (old_options) {
     if (options->UseEntryGuards && !old_options->UseEntryGuards) {