Sequencing the using and try clauses as they were before, but this shows that that obsolete function is not catching 404's as it should...

bulletsim
Diva Canto 2011-05-12 18:53:22 -07:00
parent 42bfab84b8
commit 9e310a0c0f
1 changed files with 7 additions and 7 deletions

View File

@ -976,9 +976,9 @@ namespace OpenSim.Framework
} }
} }
using (WebResponse resp = request.GetResponse()) try
{ {
try using (WebResponse resp = request.GetResponse())
{ {
if (resp.ContentLength > 0) if (resp.ContentLength > 0)
{ {
@ -988,11 +988,11 @@ namespace OpenSim.Framework
respStream.Close(); respStream.Close();
} }
} }
catch (System.InvalidOperationException) }
{ catch (System.InvalidOperationException)
// This is what happens when there is invalid XML {
m_log.WarnFormat("[SynchronousRestObjectRequester]: Invalid XML {0} {1}", requestUrl, typeof(TResponse).ToString()); // This is what happens when there is invalid XML
} m_log.WarnFormat("[SynchronousRestObjectRequester]: Invalid XML {0} {1}", requestUrl, typeof(TResponse).ToString());
} }
return deserial; return deserial;
} }