[Modify] Polish it

This commit is contained in:
sta 2019-07-25 20:08:16 +09:00
parent d29f8b5543
commit e3201e336f

View File

@ -581,13 +581,16 @@ namespace WebSocketSharp
return ret;
}
internal static byte[] InternalToByteArray (this ulong value, ByteOrder order)
internal static byte[] InternalToByteArray (
this ulong value, ByteOrder order
)
{
var bytes = BitConverter.GetBytes (value);
if (!order.IsHostOrder ())
Array.Reverse (bytes);
var ret = BitConverter.GetBytes (value);
return bytes;
if (!order.IsHostOrder ())
Array.Reverse (ret);
return ret;
}
internal static bool IsCompressionExtension (