From c6dd670d584a1e9334839422641eeca54dc7902f Mon Sep 17 00:00:00 2001 From: John Hurliman Date: Tue, 23 Feb 2010 14:58:36 -0800 Subject: [PATCH] Streamlined error logging for malformed packets and fixed a bug when printing the hex dump --- OpenSim/Region/ClientStack/LindenUDP/LLUDPServer.cs | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/OpenSim/Region/ClientStack/LindenUDP/LLUDPServer.cs b/OpenSim/Region/ClientStack/LindenUDP/LLUDPServer.cs index 2d956fac22..36d24e8200 100644 --- a/OpenSim/Region/ClientStack/LindenUDP/LLUDPServer.cs +++ b/OpenSim/Region/ClientStack/LindenUDP/LLUDPServer.cs @@ -596,15 +596,14 @@ namespace OpenSim.Region.ClientStack.LindenUDP } catch (MalformedDataException) { - m_log.ErrorFormat("[LLUDPSERVER]: Malformed data, cannot parse packet from {0}:\n{1}", - buffer.RemoteEndPoint, Utils.BytesToHexString(buffer.Data, buffer.DataLength, null)); } // Fail-safe check if (packet == null) { - m_log.Warn("[LLUDPSERVER]: Couldn't build a message from incoming data " + buffer.DataLength + - " bytes long from " + buffer.RemoteEndPoint); + m_log.ErrorFormat("[LLUDPSERVER]: Malformed data, cannot parse {0} byte packet from {1}:", + buffer.DataLength, buffer.RemoteEndPoint); + m_log.Error(Utils.BytesToHexString(buffer.Data, buffer.DataLength, null)); return; }