Save some time by calculating the routing table entry size just once
Fix memory leak

Fixes #18