Rename SocketException to more general ProtocolException
Check received event array size