private void ClientSending(object pmMain = null) { try { while (this.working) { RealmPacket rp = outRPQueue.Dequeue(); if (rp != null) { int sentLength = clientSocket.Send(rp.GetPacketBuffer()); if (sentLength < 1) { MLogger.NetworkLogger.Error("Realm client socket sent 0 bytes : " + this.clientSocket.Handle); this.StopSession(); } } Thread.Sleep(10); } } catch (Exception exp) { MLogger.NetworkLogger.Error("Realm client sending exp :" + this.clientSocket.Handle + " " + exp.Message); this.StopSession(); } }