add debug code to SocketEndPoint class