diff options
Merge commit '464201b41d5f5fdd7c88ab5e95dd7b6fbae6d766' into careminster
Diffstat (limited to 'OpenSim/Framework/Servers/HttpServer/BaseHttpServer.cs')
-rw-r--r-- | OpenSim/Framework/Servers/HttpServer/BaseHttpServer.cs | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/OpenSim/Framework/Servers/HttpServer/BaseHttpServer.cs b/OpenSim/Framework/Servers/HttpServer/BaseHttpServer.cs index df1950d..97035e3 100644 --- a/OpenSim/Framework/Servers/HttpServer/BaseHttpServer.cs +++ b/OpenSim/Framework/Servers/HttpServer/BaseHttpServer.cs | |||
@@ -487,7 +487,9 @@ namespace OpenSim.Framework.Servers.HttpServer | |||
487 | { | 487 | { |
488 | try | 488 | try |
489 | { | 489 | { |
490 | SendHTML500(response); | 490 | byte[] buffer500 = SendHTML500(response); |
491 | response.Body.Write(buffer500,0,buffer500.Length); | ||
492 | response.Body.Close(); | ||
491 | } | 493 | } |
492 | catch | 494 | catch |
493 | { | 495 | { |
@@ -720,7 +722,15 @@ namespace OpenSim.Framework.Servers.HttpServer | |||
720 | catch (Exception e) | 722 | catch (Exception e) |
721 | { | 723 | { |
722 | m_log.Error(String.Format("[BASE HTTP SERVER]: HandleRequest() threw {0} ", e.StackTrace), e); | 724 | m_log.Error(String.Format("[BASE HTTP SERVER]: HandleRequest() threw {0} ", e.StackTrace), e); |
723 | SendHTML500(response); | 725 | try |
726 | { | ||
727 | byte[] buffer500 = SendHTML500(response); | ||
728 | response.Body.Write(buffer500, 0, buffer500.Length); | ||
729 | response.Body.Close(); | ||
730 | } | ||
731 | catch | ||
732 | { | ||
733 | } | ||
724 | } | 734 | } |
725 | finally | 735 | finally |
726 | { | 736 | { |
@@ -1792,7 +1802,8 @@ namespace OpenSim.Framework.Servers.HttpServer | |||
1792 | response.SendChunked = false; | 1802 | response.SendChunked = false; |
1793 | response.ContentLength64 = buffer.Length; | 1803 | response.ContentLength64 = buffer.Length; |
1794 | response.ContentEncoding = Encoding.UTF8; | 1804 | response.ContentEncoding = Encoding.UTF8; |
1795 | 1805 | ||
1806 | |||
1796 | return buffer; | 1807 | return buffer; |
1797 | } | 1808 | } |
1798 | 1809 | ||