socket: code style
socket: don't call `socket#onclose` if previous state was not `open`
socket: added missing `socket#onerror` support
socket: ignore further transport communication upon `onClose`
transports: improve polling orderly close (fixes #164)
Release 0.6.2