diff options
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Framework/Servers/BaseHttpServer.cs | 8 | ||||
-rw-r--r-- | OpenSim/Framework/Servers/BinaryStreamHandler.cs | 2 |
2 files changed, 5 insertions, 5 deletions
diff --git a/OpenSim/Framework/Servers/BaseHttpServer.cs b/OpenSim/Framework/Servers/BaseHttpServer.cs index 7c268ed..088d944 100644 --- a/OpenSim/Framework/Servers/BaseHttpServer.cs +++ b/OpenSim/Framework/Servers/BaseHttpServer.cs | |||
@@ -496,7 +496,7 @@ namespace OpenSim.Framework.Servers | |||
496 | } | 496 | } |
497 | } | 497 | } |
498 | 498 | ||
499 | private void DoHTTPGruntWork(Hashtable responsedata, HttpListenerResponse response) | 499 | private static void DoHTTPGruntWork(Hashtable responsedata, HttpListenerResponse response) |
500 | { | 500 | { |
501 | int responsecode = (int)responsedata["int_response_code"]; | 501 | int responsecode = (int)responsedata["int_response_code"]; |
502 | string responseString = (string)responsedata["str_response_string"]; | 502 | string responseString = (string)responsedata["str_response_string"]; |
@@ -505,7 +505,7 @@ namespace OpenSim.Framework.Servers | |||
505 | //Even though only one other part of the entire code uses HTTPHandlers, we shouldn't expect this | 505 | //Even though only one other part of the entire code uses HTTPHandlers, we shouldn't expect this |
506 | //and should check for NullReferenceExceptions | 506 | //and should check for NullReferenceExceptions |
507 | 507 | ||
508 | if (contentType == null || contentType == "") | 508 | if (string.IsNullOrEmpty(contentType)) |
509 | { | 509 | { |
510 | contentType = "text/html"; | 510 | contentType = "text/html"; |
511 | } | 511 | } |
@@ -677,12 +677,12 @@ namespace OpenSim.Framework.Servers | |||
677 | } | 677 | } |
678 | 678 | ||
679 | // Fallback HTTP responses in case the HTTP error response files don't exist | 679 | // Fallback HTTP responses in case the HTTP error response files don't exist |
680 | private string getDefaultHTTP404(string host) | 680 | private static string getDefaultHTTP404(string host) |
681 | { | 681 | { |
682 | return "<HTML><HEAD><TITLE>404 Page not found</TITLE><BODY><BR /><H1>Ooops!</H1><P>The page you requested has been obsconded with by knomes. Find hippos quick!</P><P>If you are trying to log-in, your link parameters should have: "-loginpage http://" + host + "/?method=login -loginuri http://" + host + "/" in your link </P></BODY></HTML>"; | 682 | return "<HTML><HEAD><TITLE>404 Page not found</TITLE><BODY><BR /><H1>Ooops!</H1><P>The page you requested has been obsconded with by knomes. Find hippos quick!</P><P>If you are trying to log-in, your link parameters should have: "-loginpage http://" + host + "/?method=login -loginuri http://" + host + "/" in your link </P></BODY></HTML>"; |
683 | } | 683 | } |
684 | 684 | ||
685 | private string getDefaultHTTP500() | 685 | private static string getDefaultHTTP500() |
686 | { | 686 | { |
687 | return "<HTML><HEAD><TITLE>500 Internal Server Error</TITLE><BODY><BR /><H1>Ooops!</H1><P>The server you requested is overun by knomes! Find hippos quick!</P></BODY></HTML>"; | 687 | return "<HTML><HEAD><TITLE>500 Internal Server Error</TITLE><BODY><BR /><H1>Ooops!</H1><P>The server you requested is overun by knomes! Find hippos quick!</P></BODY></HTML>"; |
688 | } | 688 | } |
diff --git a/OpenSim/Framework/Servers/BinaryStreamHandler.cs b/OpenSim/Framework/Servers/BinaryStreamHandler.cs index bfa3bd5..dcd1cba 100644 --- a/OpenSim/Framework/Servers/BinaryStreamHandler.cs +++ b/OpenSim/Framework/Servers/BinaryStreamHandler.cs | |||
@@ -51,7 +51,7 @@ namespace OpenSim.Framework.Servers | |||
51 | m_method = binaryMethod; | 51 | m_method = binaryMethod; |
52 | } | 52 | } |
53 | 53 | ||
54 | private byte[] ReadFully(Stream stream) | 54 | private static byte[] ReadFully(Stream stream) |
55 | { | 55 | { |
56 | byte[] buffer = new byte[32768]; | 56 | byte[] buffer = new byte[32768]; |
57 | using (MemoryStream ms = new MemoryStream()) | 57 | using (MemoryStream ms = new MemoryStream()) |