private void OnProtocolError(object sender, ProtocolErrorEventArgs e) { this.End(StatusCode.ProtocolError); if (this.OnError != null) { this.OnError(this, e); } }