* Set KeepAlive to false for logins so logins after the first won't break
* Set Expect100Continue to false to prevent an unnecessary handshake in HTTP POST exchanges git-svn-id: http://libopenmetaverse.googlecode.com/svn/trunk@1131 52acb1d6-8a22-11de-b505-999d5b087335
This commit is contained in:
@@ -303,7 +303,8 @@ namespace libsecondlife
|
||||
byte[] bytes = Encoding.UTF8.GetBytes(output.ToString());
|
||||
|
||||
LoginRequest = (HttpWebRequest)HttpWebRequest.Create(loginParams.URI);
|
||||
LoginRequest.Timeout = loginParams.Timeout;
|
||||
LoginRequest.Timeout = loginParams.Timeout; // TODO: This won't do anything with async calls
|
||||
LoginRequest.KeepAlive = false;
|
||||
LoginRequest.Method = "POST";
|
||||
LoginRequest.ContentType = "text/xml";
|
||||
LoginRequest.ContentLength = bytes.Length;
|
||||
|
||||
@@ -216,6 +216,9 @@ namespace libsecondlife
|
||||
DisconnectTimer = new System.Timers.Timer();
|
||||
DisconnectTimer.Elapsed += new ElapsedEventHandler(DisconnectTimer_Elapsed);
|
||||
|
||||
// Don't force Expect-100: Continue headers on HTTP POST calls
|
||||
ServicePointManager.Expect100Continue = false;
|
||||
|
||||
// Catch exceptions from threads in the managed threadpool
|
||||
Toub.Threading.ManagedThreadPool.UnhandledException +=
|
||||
new UnhandledExceptionEventHandler(ManagedThreadPool_UnhandledException);
|
||||
|
||||
Reference in New Issue
Block a user