diff options
author | lbsa71 | 2008-02-25 15:36:24 +0000 |
---|---|---|
committer | lbsa71 | 2008-02-25 15:36:24 +0000 |
commit | 5b3897a4af247a14dfd36fa00bb6999e0a1078d5 (patch) | |
tree | 7e70f5fdc18f458c813808ab5ef5486a80ea9604 /OpenSim/Framework/Servers/BaseHttpServer.cs | |
parent | Updated paths in classaudit script. (diff) | |
download | opensim-SC-5b3897a4af247a14dfd36fa00bb6999e0a1078d5.zip opensim-SC-5b3897a4af247a14dfd36fa00bb6999e0a1078d5.tar.gz opensim-SC-5b3897a4af247a14dfd36fa00bb6999e0a1078d5.tar.bz2 opensim-SC-5b3897a4af247a14dfd36fa00bb6999e0a1078d5.tar.xz |
* Caught HttpListenerException and swallowed if with output
* Moved Flush into Close since it's always done in that order.
* Minor renamings
* Reversed if for clarity
Diffstat (limited to 'OpenSim/Framework/Servers/BaseHttpServer.cs')
-rw-r--r-- | OpenSim/Framework/Servers/BaseHttpServer.cs | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/OpenSim/Framework/Servers/BaseHttpServer.cs b/OpenSim/Framework/Servers/BaseHttpServer.cs index dc540f9..e61cc80 100644 --- a/OpenSim/Framework/Servers/BaseHttpServer.cs +++ b/OpenSim/Framework/Servers/BaseHttpServer.cs | |||
@@ -154,8 +154,16 @@ namespace OpenSim.Framework.Servers | |||
154 | request.InputStream.Close(); | 154 | request.InputStream.Close(); |
155 | response.ContentType = requestHandler.ContentType; | 155 | response.ContentType = requestHandler.ContentType; |
156 | response.ContentLength64 = buffer.LongLength; | 156 | response.ContentLength64 = buffer.LongLength; |
157 | response.OutputStream.Write(buffer, 0, buffer.Length); | 157 | |
158 | response.OutputStream.Close(); | 158 | try |
159 | { | ||
160 | response.OutputStream.Write(buffer, 0, buffer.Length); | ||
161 | response.OutputStream.Close(); | ||
162 | } | ||
163 | catch (HttpListenerException e) | ||
164 | { | ||
165 | m_log.InfoFormat("[BASEHTTPSERVER] Http request abnormally terminated."); | ||
166 | } | ||
159 | } | 167 | } |
160 | else | 168 | else |
161 | { | 169 | { |