aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Framework/Servers/HttpServer/OSHttpRequest.cs
diff options
context:
space:
mode:
authorMelanie2009-12-05 19:53:54 +0000
committerMelanie2009-12-05 19:53:54 +0000
commit43a6fa1d01707fda74b8ba7c2d9fb95210463b6a (patch)
tree77c5897901544e82467b1cdfafdc63644ee821ef /OpenSim/Framework/Servers/HttpServer/OSHttpRequest.cs
parentMerge branch 'master' into careminster (diff)
parent* Fix line endings in BaseHttpServer.cs (diff)
downloadopensim-SC-43a6fa1d01707fda74b8ba7c2d9fb95210463b6a.zip
opensim-SC-43a6fa1d01707fda74b8ba7c2d9fb95210463b6a.tar.gz
opensim-SC-43a6fa1d01707fda74b8ba7c2d9fb95210463b6a.tar.bz2
opensim-SC-43a6fa1d01707fda74b8ba7c2d9fb95210463b6a.tar.xz
Merge branch 'master' into careminster
Diffstat (limited to 'OpenSim/Framework/Servers/HttpServer/OSHttpRequest.cs')
-rw-r--r--OpenSim/Framework/Servers/HttpServer/OSHttpRequest.cs10
1 files changed, 9 insertions, 1 deletions
diff --git a/OpenSim/Framework/Servers/HttpServer/OSHttpRequest.cs b/OpenSim/Framework/Servers/HttpServer/OSHttpRequest.cs
index c53160f..bcfb0a4 100644
--- a/OpenSim/Framework/Servers/HttpServer/OSHttpRequest.cs
+++ b/OpenSim/Framework/Servers/HttpServer/OSHttpRequest.cs
@@ -188,7 +188,15 @@ namespace OpenSim.Framework.Servers.HttpServer
188 try 188 try
189 { 189 {
190 IPAddress addr = IPAddress.Parse(req.Headers["remote_addr"]); 190 IPAddress addr = IPAddress.Parse(req.Headers["remote_addr"]);
191 int port = Int32.Parse(req.Headers["remote_port"]); 191 // sometimes req.Headers["remote_port"] returns a comma separated list, so use
192 // the first one in the list and log it
193 string[] strPorts = req.Headers["remote_port"].Split(new char[] { ',' });
194 if (strPorts.Length > 1)
195 {
196 _log.ErrorFormat("[OSHttpRequest]: format exception on addr/port {0}:{1}, ignoring",
197 req.Headers["remote_addr"], req.Headers["remote_port"]);
198 }
199 int port = Int32.Parse(strPorts[0]);
192 _remoteIPEndPoint = new IPEndPoint(addr, port); 200 _remoteIPEndPoint = new IPEndPoint(addr, port);
193 } 201 }
194 catch (FormatException) 202 catch (FormatException)