Browse Source

discourage people from setting their dirfetchpostperiod more often
than once per minute


svn:r2369

Roger Dingledine 21 years ago
parent
commit
02e3e3327c
1 changed files with 3 additions and 2 deletions
  1. 3 2
      src/or/config.c

+ 3 - 2
src/or/config.c

@@ -841,8 +841,9 @@ int getconfig(int argc, char **argv, or_options_t *options) {
     result = -1;
   }
 
-  if(options->DirFetchPostPeriod < 1) {
-    log(LOG_WARN,"DirFetchPostPeriod option must be positive.");
+#define MIN_DIRFETCHPOSTPERIOD 60
+  if(options->DirFetchPostPeriod < MIN_DIRFETCHPOSTPERIOD) {
+    log(LOG_WARN,"DirFetchPostPeriod option must be at least %d.", MIN_DIRFETCHPOSTPERIOD);
     result = -1;
   }
   if(options->DirFetchPostPeriod > MIN_ONION_KEY_LIFETIME/2) {