this prevents a crash when some non-netmgr thread, such as a recursive lookup, times out after the TCP socket is already disconnected.