private void SendBytes(byte[] Buffer) { int MinCompress = 250; bool bCompress = (Encoder != null); if (bCompress && (Buffer.Length <= MinCompress)) { bCompress = false; } #if DEBUG bCompress = (Encoder != null); #endif if (bCompress) { Buffer = Encoder.Compress(Buffer); } byte[] bHybi = Hybi.HybiEncode(Buffer, bCompress); if (!SendRaw(bHybi)) { Console.WriteLine("Sendraw failed?"); throw new Exception("Sendraw failed?"); } }