From cea6e03ae0aaea3acba6b844f173ee08259fe101 Mon Sep 17 00:00:00 2001 From: Dr Scofield Date: Fri, 27 Jun 2008 16:18:56 +0000 Subject: [PATCH] dr scofield's warning safari: hunting down those little buggers --- OpenSim/Framework/Communications/XMPP/XmppMessageStanza.cs | 2 +- OpenSim/Framework/Servers/OSHttpRequest.cs | 4 ++-- OpenSim/Framework/Servers/OSHttpRequestPump.cs | 4 ++-- OpenSim/Framework/Servers/RestObjectPoster.cs | 3 ++- 4 files changed, 7 insertions(+), 6 deletions(-) diff --git a/OpenSim/Framework/Communications/XMPP/XmppMessageStanza.cs b/OpenSim/Framework/Communications/XMPP/XmppMessageStanza.cs index b221459083..fd4cd5f0b1 100644 --- a/OpenSim/Framework/Communications/XMPP/XmppMessageStanza.cs +++ b/OpenSim/Framework/Communications/XMPP/XmppMessageStanza.cs @@ -60,7 +60,7 @@ namespace OpenSim.Framework.Communications.XMPP Text = message; } - public string ToString() + new public string ToString() { return Text; } diff --git a/OpenSim/Framework/Servers/OSHttpRequest.cs b/OpenSim/Framework/Servers/OSHttpRequest.cs index 10614b230a..1eb094e59c 100644 --- a/OpenSim/Framework/Servers/OSHttpRequest.cs +++ b/OpenSim/Framework/Servers/OSHttpRequest.cs @@ -57,7 +57,7 @@ namespace OpenSim.Framework.Servers private string _userAgent; private HttpRequest _request; - private HttpClientContext _context; + // private HttpClientContext _context; public string[] AcceptTypes { @@ -175,7 +175,7 @@ namespace OpenSim.Framework.Servers public OSHttpRequest(HttpClientContext context, HttpRequest req) { - _context = context; + // _context = context; _request = req; } } diff --git a/OpenSim/Framework/Servers/OSHttpRequestPump.cs b/OpenSim/Framework/Servers/OSHttpRequestPump.cs index f04134cfc5..3459cc625c 100644 --- a/OpenSim/Framework/Servers/OSHttpRequestPump.cs +++ b/OpenSim/Framework/Servers/OSHttpRequestPump.cs @@ -147,8 +147,6 @@ namespace OpenSim.Framework.Servers Dictionary headerRegexs = h.Headers; Regex endPointsRegex = h.IPEndPointWhitelist; - int pathMatch = 0; - int headersMatch = 0; // first, check whether IPEndPointWhitelist applies // and, if it does, whether client is on that white @@ -175,6 +173,8 @@ namespace OpenSim.Framework.Servers // whitelist & path ok, now check headers if (null != headerRegexs) { + int headersMatch = 0; + // go through all header Regexs and evaluate // match: // if header field not present or does not match: diff --git a/OpenSim/Framework/Servers/RestObjectPoster.cs b/OpenSim/Framework/Servers/RestObjectPoster.cs index c77cb26c5d..c449d0169f 100644 --- a/OpenSim/Framework/Servers/RestObjectPoster.cs +++ b/OpenSim/Framework/Servers/RestObjectPoster.cs @@ -69,7 +69,8 @@ namespace OpenSim.Framework.Servers Stream requestStream = request.GetRequestStream(); requestStream.Write(buffer.ToArray(), 0, length); - IAsyncResult result = request.BeginGetResponse(AsyncCallback, request); + // IAsyncResult result = request.BeginGetResponse(AsyncCallback, request); + request.BeginGetResponse(AsyncCallback, request); } private static void AsyncCallback(IAsyncResult result)