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

[or-cvs] r15130: forward-port r15129, but also note the real way we should fi (tor/trunk/src/or)



Author: arma
Date: 2008-06-11 07:12:29 -0400 (Wed, 11 Jun 2008)
New Revision: 15130

Modified:
   tor/trunk/src/or/config.c
Log:
forward-port r15129, but also note the real way we should fix it.


Modified: tor/trunk/src/or/config.c
===================================================================
--- tor/trunk/src/or/config.c	2008-06-11 11:09:55 UTC (rev 15129)
+++ tor/trunk/src/or/config.c	2008-06-11 11:12:29 UTC (rev 15130)
@@ -3444,6 +3444,10 @@
 options_transition_affects_descriptor(or_options_t *old_options,
                                       or_options_t *new_options)
 {
+  /* XXX021 We can be smarter here. If your DirPort isn't being
+   * published and you just turned it off, no need to republish. If
+   * you changed your bandwidthrate but maxadvertisedbandwidth still
+   * trumps, no need to republish. Etc. */
   if (!opt_streq(old_options->DataDirectory, new_options->DataDirectory) ||
       !opt_streq(old_options->Nickname,new_options->Nickname) ||
       !opt_streq(old_options->Address,new_options->Address) ||
@@ -3458,6 +3462,8 @@
         new_options->_PublishServerDescriptor ||
       old_options->BandwidthRate != new_options->BandwidthRate ||
       old_options->BandwidthBurst != new_options->BandwidthBurst ||
+      old_options->MaxAdvertisedBandwidth !=
+        new_options->MaxAdvertisedBandwidth ||
       !opt_streq(old_options->ContactInfo, new_options->ContactInfo) ||
       !opt_streq(old_options->MyFamily, new_options->MyFamily) ||
       !opt_streq(old_options->AccountingStart, new_options->AccountingStart) ||