From ee5e61d448dc72bc84af28dbae64fe29c7dd99e4 Mon Sep 17 00:00:00 2001 From: "Justin Clark-Casey (justincc)" Date: Tue, 20 Nov 2012 04:10:03 +0000 Subject: [PATCH] minor: If logging full incoming HTTP data, don't deceptively print ... at the end of the body. --- OpenSim/Framework/Servers/HttpServer/BaseHttpServer.cs | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/OpenSim/Framework/Servers/HttpServer/BaseHttpServer.cs b/OpenSim/Framework/Servers/HttpServer/BaseHttpServer.cs index d5bf1d20a1..ed8cb97f8f 100644 --- a/OpenSim/Framework/Servers/HttpServer/BaseHttpServer.cs +++ b/OpenSim/Framework/Servers/HttpServer/BaseHttpServer.cs @@ -719,8 +719,11 @@ namespace OpenSim.Framework.Servers.HttpServer if (DebugLevel == 5) { const int sampleLength = 80; - char[] sampleChars = new char[sampleLength]; + char[] sampleChars = new char[sampleLength + 3]; reader.Read(sampleChars, 0, sampleLength); + sampleChars[80] = '.'; + sampleChars[81] = '.'; + sampleChars[82] = '.'; output = new string(sampleChars); } else @@ -728,7 +731,7 @@ namespace OpenSim.Framework.Servers.HttpServer output = reader.ReadToEnd(); } - m_log.DebugFormat("[BASE HTTP SERVER]: {0}...", output.Replace("\n", @"\n")); + m_log.DebugFormat("[BASE HTTP SERVER]: {0}", output.Replace("\n", @"\n")); } }