move periodic switch maintenance into the router instead of its own goroutine

This commit is contained in:
Arceliar 2018-06-06 23:10:33 -05:00
parent 5dc0cb5544
commit 3b783fbf97
4 changed files with 2 additions and 23 deletions

View file

@ -91,6 +91,7 @@ func (r *router) mainLoop() {
case <-ticker.C:
{
// Any periodic maintenance stuff goes here
r.core.switchTable.doMaintenance()
r.core.dht.doMaintenance()
util_getBytes() // To slowly drain things
}