Bladeren bron

Make keypin.c dirauth-only

Nick Mathewson 5 jaren geleden
bovenliggende
commit
a45413e7d5
3 gewijzigde bestanden met toevoegingen van 3 en 3 verwijderingen
  1. 0 1
      src/app/main/shutdown.c
  2. 1 2
      src/core/include.am
  3. 2 0
      src/feature/dirauth/dirauth_sys.c

+ 0 - 1
src/app/main/shutdown.c

@@ -97,7 +97,6 @@ tor_cleanup(void)
     }
     if (authdir_mode_tests_reachability(options))
       rep_hist_record_mtbf_data(now, 0);
-    keypin_close_journal();
   }
 
   timers_shutdown();

+ 1 - 2
src/core/include.am

@@ -81,7 +81,6 @@ LIBTOR_APP_A_SOURCES = 				\
 	src/feature/control/control_getinfo.c	\
 	src/feature/control/fmt_serverstatus.c  \
 	src/feature/control/getinfo_geoip.c	\
-	src/feature/dirauth/keypin.c		\
 	src/feature/dircache/conscache.c	\
 	src/feature/dircache/consdiffmgr.c	\
 	src/feature/dircache/dircache.c		\
@@ -118,7 +117,6 @@ LIBTOR_APP_A_SOURCES = 				\
 	src/feature/hs_common/replaycache.c	\
 	src/feature/hs_common/shared_random_client.c	\
 	src/feature/keymgt/loadkey.c		\
-	src/feature/dirauth/keypin.c		\
 	src/feature/nodelist/authcert.c		\
 	src/feature/nodelist/describe.c		\
 	src/feature/nodelist/dirlist.c		\
@@ -173,6 +171,7 @@ MODULE_DIRAUTH_SOURCES = 					\
 	src/feature/dirauth/dirvote.c				\
 	src/feature/dirauth/dsigs_parse.c			\
 	src/feature/dirauth/guardfraction.c			\
+	src/feature/dirauth/keypin.c				\
 	src/feature/dirauth/process_descs.c			\
 	src/feature/dirauth/reachability.c			\
 	src/feature/dirauth/recommend_pkg.c			\

+ 2 - 0
src/feature/dirauth/dirauth_sys.c

@@ -10,6 +10,7 @@
 #include "feature/dirauth/dirauth_sys.h"
 #include "feature/dirauth/dirvote.h"
 #include "feature/dirauth/dirauth_periodic.h"
+#include "feature/dirauth/keypin.h"
 #include "feature/dirauth/process_descs.h"
 
 #include "lib/subsys/subsys.h"
@@ -27,6 +28,7 @@ subsys_dirauth_shutdown(void)
   dirserv_free_fingerprint_list();
   dirvote_free_all();
   dirserv_clear_measured_bw_cache();
+  keypin_close_journal();
 }
 
 const struct subsys_fns_t sys_dirauth = {