relay CloseEvent code when socket closed uncleanly