[tor-commits] [tor/master] Refactoring: Move code that creates listener for port into new function