diff options
Diffstat (limited to '')
-rw-r--r-- | OpenSim/ApplicationPlugins/Rest/Inventory/Rest.cs | 23 |
1 files changed, 11 insertions, 12 deletions
diff --git a/OpenSim/ApplicationPlugins/Rest/Inventory/Rest.cs b/OpenSim/ApplicationPlugins/Rest/Inventory/Rest.cs index bfa27c3..2ac1001 100644 --- a/OpenSim/ApplicationPlugins/Rest/Inventory/Rest.cs +++ b/OpenSim/ApplicationPlugins/Rest/Inventory/Rest.cs | |||
@@ -30,18 +30,17 @@ using System; | |||
30 | using System.Collections.Generic; | 30 | using System.Collections.Generic; |
31 | using System.Reflection; | 31 | using System.Reflection; |
32 | using System.Text; | 32 | using System.Text; |
33 | using log4net; | ||
34 | using Nini.Config; | ||
33 | using OpenSim.Framework; | 35 | using OpenSim.Framework; |
34 | using OpenSim.Framework.Servers; | ||
35 | using OpenSim.Framework.Communications; | 36 | using OpenSim.Framework.Communications; |
36 | using OpenSim.Framework.Communications.Cache; | ||
37 | using Nini.Config; | ||
38 | 37 | ||
39 | namespace OpenSim.ApplicationPlugins.Rest.Inventory | 38 | namespace OpenSim.ApplicationPlugins.Rest.Inventory |
40 | { | 39 | { |
41 | public class Rest | 40 | public class Rest |
42 | { | 41 | { |
43 | internal static readonly log4net.ILog Log = | 42 | internal static readonly ILog Log = |
44 | log4net.LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); | 43 | LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); |
45 | 44 | ||
46 | internal static bool DEBUG = Log.IsDebugEnabled; | 45 | internal static bool DEBUG = Log.IsDebugEnabled; |
47 | 46 | ||
@@ -468,25 +467,25 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory | |||
468 | 467 | ||
469 | public static void Dump(byte[] data) | 468 | public static void Dump(byte[] data) |
470 | { | 469 | { |
471 | char[] buffer = new char[Rest.DumpLineSize]; | 470 | char[] buffer = new char[DumpLineSize]; |
472 | int cc = 0; | 471 | int cc = 0; |
473 | 472 | ||
474 | for (int i = 0; i < data.Length; i++) | 473 | for (int i = 0; i < data.Length; i++) |
475 | { | 474 | { |
476 | if (i % Rest.DumpLineSize == 0) Console.Write("\n{0}: ",i.ToString("d8")); | 475 | if (i % DumpLineSize == 0) Console.Write("\n{0}: ",i.ToString("d8")); |
477 | 476 | ||
478 | if (i % 4 == 0) Console.Write(" "); | 477 | if (i % 4 == 0) Console.Write(" "); |
479 | 478 | ||
480 | Console.Write("{0}",data[i].ToString("x2")); | 479 | Console.Write("{0}",data[i].ToString("x2")); |
481 | 480 | ||
482 | if (data[i] < 127 && data[i] > 31) | 481 | if (data[i] < 127 && data[i] > 31) |
483 | buffer[i % Rest.DumpLineSize] = (char) data[i]; | 482 | buffer[i % DumpLineSize] = (char) data[i]; |
484 | else | 483 | else |
485 | buffer[i % Rest.DumpLineSize] = '.'; | 484 | buffer[i % DumpLineSize] = '.'; |
486 | 485 | ||
487 | cc++; | 486 | cc++; |
488 | 487 | ||
489 | if (i != 0 && (i + 1) % Rest.DumpLineSize == 0) | 488 | if (i != 0 && (i + 1) % DumpLineSize == 0) |
490 | { | 489 | { |
491 | Console.Write(" |"+(new String(buffer))+"|"); | 490 | Console.Write(" |"+(new String(buffer))+"|"); |
492 | cc = 0; | 491 | cc = 0; |
@@ -497,11 +496,11 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory | |||
497 | 496 | ||
498 | if (cc != 0) | 497 | if (cc != 0) |
499 | { | 498 | { |
500 | for (int i = cc ; i < Rest.DumpLineSize; i++) | 499 | for (int i = cc ; i < DumpLineSize; i++) |
501 | { | 500 | { |
502 | if (i % 4 == 0) Console.Write(" "); | 501 | if (i % 4 == 0) Console.Write(" "); |
503 | Console.Write(" "); | 502 | Console.Write(" "); |
504 | buffer[i % Rest.DumpLineSize] = ' '; | 503 | buffer[i % DumpLineSize] = ' '; |
505 | } | 504 | } |
506 | Console.WriteLine(" |"+(new String(buffer))+"|"); | 505 | Console.WriteLine(" |"+(new String(buffer))+"|"); |
507 | } | 506 | } |