summaryrefslogtreecommitdiff
path: root/src/or/main.c
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2004-06-06 03:38:31 +0000
committerNick Mathewson <nickm@torproject.org>2004-06-06 03:38:31 +0000
commit184f4e6044daf853583edfee625d88eadeefab71 (patch)
tree58bffd58139d62f066095fdf1b359dd50f06baa6 /src/or/main.c
parent0d1b4b50249f10944f8d3610110a0d310e314ab3 (diff)
downloadtor-184f4e6044daf853583edfee625d88eadeefab71.tar.gz
tor-184f4e6044daf853583edfee625d88eadeefab71.zip
Rotate dnsworkers and cpuworkers on SIGHUP, so they get new config settings too
svn:r1950
Diffstat (limited to 'src/or/main.c')
-rw-r--r--src/or/main.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/or/main.c b/src/or/main.c
index 7f2c309c01..7b29f1188a 100644
--- a/src/or/main.c
+++ b/src/or/main.c
@@ -638,6 +638,11 @@ static int do_hup(void) {
directory_get_from_dirserver(DIR_PURPOSE_FETCH_DIR, NULL, 0);
}
if(options.ORPort) {
+ /* Restart cpuworker and dnsworker processes, so they get up-to-date
+ * configuration options. */
+ cpuworkers_rotate();
+ dnsworkers_rotate();
+ /* Rebuild fresh descriptor as needed. */
router_rebuild_descriptor();
sprintf(keydir,"%s/router.desc", options.DataDirectory);
log_fn(LOG_INFO,"Dumping descriptor to %s...",keydir);