[tor-commits] [tor/master] Fix cases where the tests were doing closesocket() on a non-socket