diff options
Diffstat (limited to 'OpenSim/Framework/Servers/HttpServer/BaseHttpServer.cs')
-rw-r--r-- | OpenSim/Framework/Servers/HttpServer/BaseHttpServer.cs | 36 |
1 files changed, 31 insertions, 5 deletions
diff --git a/OpenSim/Framework/Servers/HttpServer/BaseHttpServer.cs b/OpenSim/Framework/Servers/HttpServer/BaseHttpServer.cs index 3de7f9c..24f986a 100644 --- a/OpenSim/Framework/Servers/HttpServer/BaseHttpServer.cs +++ b/OpenSim/Framework/Servers/HttpServer/BaseHttpServer.cs | |||
@@ -1447,10 +1447,34 @@ namespace OpenSim.Framework.Servers.HttpServer | |||
1447 | 1447 | ||
1448 | internal byte[] DoHTTPGruntWork(Hashtable responsedata, OSHttpResponse response) | 1448 | internal byte[] DoHTTPGruntWork(Hashtable responsedata, OSHttpResponse response) |
1449 | { | 1449 | { |
1450 | //m_log.Info("[BASE HTTP SERVER]: Doing HTTP Grunt work with response"); | 1450 | int responsecode; |
1451 | int responsecode = (int)responsedata["int_response_code"]; | 1451 | string responseString; |
1452 | string responseString = (string)responsedata["str_response_string"]; | 1452 | string contentType; |
1453 | string contentType = (string)responsedata["content_type"]; | 1453 | |
1454 | if (responsedata == null) | ||
1455 | { | ||
1456 | responsecode = 500; | ||
1457 | responseString = "No response could be obtained"; | ||
1458 | contentType = "text/plain"; | ||
1459 | responsedata = new Hashtable(); | ||
1460 | } | ||
1461 | else | ||
1462 | { | ||
1463 | try | ||
1464 | { | ||
1465 | //m_log.Info("[BASE HTTP SERVER]: Doing HTTP Grunt work with response"); | ||
1466 | responsecode = (int)responsedata["int_response_code"]; | ||
1467 | responseString = (string)responsedata["str_response_string"]; | ||
1468 | contentType = (string)responsedata["content_type"]; | ||
1469 | } | ||
1470 | catch | ||
1471 | { | ||
1472 | responsecode = 500; | ||
1473 | responseString = "No response could be obtained"; | ||
1474 | contentType = "text/plain"; | ||
1475 | responsedata = new Hashtable(); | ||
1476 | } | ||
1477 | } | ||
1454 | 1478 | ||
1455 | if (responsedata.ContainsKey("error_status_text")) | 1479 | if (responsedata.ContainsKey("error_status_text")) |
1456 | { | 1480 | { |
@@ -1627,7 +1651,9 @@ namespace OpenSim.Framework.Servers.HttpServer | |||
1627 | 1651 | ||
1628 | public void httpServerException(object source, Exception exception) | 1652 | public void httpServerException(object source, Exception exception) |
1629 | { | 1653 | { |
1630 | m_log.Error(String.Format("[BASE HTTP SERVER]: {0} had an exception: {1} ", source.ToString(), exception.Message), exception); | 1654 | if (source.ToString() == "HttpServer.HttpListener" && exception.ToString().StartsWith("Mono.Security.Protocol.Tls.TlsException")) |
1655 | return; | ||
1656 | m_log.ErrorFormat("[BASE HTTP SERVER]: {0} had an exception {1}", source.ToString(), exception.ToString()); | ||
1631 | /* | 1657 | /* |
1632 | if (HTTPDRunning)// && NotSocketErrors > 5) | 1658 | if (HTTPDRunning)// && NotSocketErrors > 5) |
1633 | { | 1659 | { |