Router and memory leaks