Fix a problem with my check-in for TRQ-1830. I was closing valid sockets and then returning them for writing. D'oh\!