Added try/catch block around the method calls within toString(). Calls such as getInetAddress(), getPort() etc does not check if the socket is closed, and when applications use toString() on a closed socket, there is an uncaught exception. git-svn-id: svn://10.0.0.236/trunk@177919 18797224-902f-48f8-a5cc-f745e15eee43